diff options
author | Eugene Syromyatnikov <evgsyr@gmail.com> | 2022-06-28 17:25:09 +0200 |
---|---|---|
committer | Dmitry V. Levin <ldv@strace.io> | 2022-06-28 15:37:06 +0000 |
commit | 0c7a6ce3188a1919167608301cd44a72e7039c38 (patch) | |
tree | d4aa9e1ad8a3979fae0575a331c76ac61229846a | |
parent | 6d3e97e83a7d61cbb2f5109efb4b519383a55712 (diff) | |
download | strace-0c7a6ce3188a1919167608301cd44a72e7039c38.tar.gz |
util: constify find_xlat_val_ex arguments
They are not supposed to be modified in the function body.
* src/util.c (find_xlat_val_ex): Add const qualifiers to items, s,
num_items, and flags arguments.
-rw-r--r-- | src/util.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/util.c b/src/util.c index 93aa7b371..cd1614da0 100644 --- a/src/util.c +++ b/src/util.c @@ -34,8 +34,8 @@ #include "xstring.h" const struct xlat_data * -find_xlat_val_ex(const struct xlat_data *items, const char *s, size_t num_items, - unsigned int flags) +find_xlat_val_ex(const struct xlat_data * const items, const char * const s, + const size_t num_items, const unsigned int flags) { for (size_t i = 0; i < num_items; i++) { if (!(flags & FXL_CASE_SENSITIVE ? strcmp |