From: "Lukáš Zaoral" <lzaoral@redhat.com>
To: smatch@vger.kernel.org
Subject: [PATCH] untracked_param: fix compilation errors with GCC 14
Date: Fri, 19 Jan 2024 17:39:39 +0100 [thread overview]
Message-ID: <20240119163939.1407801-1-lzaoral@redhat.com> (raw)
select_return_states_hook expects that the passed function does not declare
the key and value arguments as const.
Signed-off-by: Lukáš Zaoral <lzaoral@redhat.com>
---
smatch.h | 2 +-
smatch_untracked_param.c | 4 ++--
2 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/smatch.h b/smatch.h
index ce09ae73..ecdbe684 100644
--- a/smatch.h
+++ b/smatch.h
@@ -1443,7 +1443,7 @@ bool buf_comp2_has_bytes(struct expression *buf_expr, struct expression *var);
bool buf_has_bytes(struct expression *buf, struct expression *var);
/* smatch_untracked_param.c */
-void mark_untracked(struct expression *expr, int param, const char *key, const char *value);
+void mark_untracked(struct expression *expr, int param, char *key, char *value);
void mark_call_params_untracked(struct expression *call);
void add_untracked_param_hook(void (func)(struct expression *call, int param));
void add_lost_param_hook(void (func)(struct expression *call, int param));
diff --git a/smatch_untracked_param.c b/smatch_untracked_param.c
index b7230f06..a84889ca 100644
--- a/smatch_untracked_param.c
+++ b/smatch_untracked_param.c
@@ -120,12 +120,12 @@ free:
}
-void mark_untracked(struct expression *expr, int param, const char *key, const char *value)
+void mark_untracked(struct expression *expr, int param, char *key, char *value)
{
mark_untracked_lost(expr, param, key, UNTRACKED_PARAM);
}
-void mark_lost(struct expression *expr, int param, const char *key, const char *value)
+void mark_lost(struct expression *expr, int param, char *key, char *value)
{
mark_untracked_lost(expr, param, key, LOST_PARAM);
}
--
2.43.0
next reply other threads:[~2024-01-19 16:39 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-01-19 16:39 Lukáš Zaoral [this message]
2024-01-22 6:25 ` [PATCH] untracked_param: fix compilation errors with GCC 14 Dan Carpenter
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20240119163939.1407801-1-lzaoral@redhat.com \
--to=lzaoral@redhat.com \
--cc=smatch@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).