diff options
author | Andreas Baumann <mail@andreasbaumann.cc> | 2025-05-09 10:49:02 +0200 |
---|---|---|
committer | Andreas Baumann <mail@andreasbaumann.cc> | 2025-05-09 10:49:02 +0200 |
commit | ec47bbbda6b99f0efc1801a424812a4dd457f9b6 (patch) | |
tree | b12e5162207f94323448fd89e0e1ab3d97ef2703 | |
parent | 22366b6958ac43e2d6d2fe63a3e880e20c4ad981 (diff) | |
download | monitoring-plugins-fix_check_apt_const_char.tar.gz |
changed filename in cmd_file_read to const char * (check_apt warning)fix_check_apt_const_char
-rw-r--r-- | lib/utils_cmd.c | 2 | ||||
-rw-r--r-- | lib/utils_cmd.h | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/lib/utils_cmd.c b/lib/utils_cmd.c index 18350ac0..9b222409 100644 --- a/lib/utils_cmd.c +++ b/lib/utils_cmd.c | |||
@@ -346,7 +346,7 @@ int cmd_run_array(char *const *argv, output *out, output *err, int flags) { | |||
346 | return _cmd_close(fd); | 346 | return _cmd_close(fd); |
347 | } | 347 | } |
348 | 348 | ||
349 | int cmd_file_read(char *filename, output *out, int flags) { | 349 | int cmd_file_read(const char *filename, output *out, int flags) { |
350 | int fd; | 350 | int fd; |
351 | if (out) | 351 | if (out) |
352 | memset(out, 0, sizeof(output)); | 352 | memset(out, 0, sizeof(output)); |
diff --git a/lib/utils_cmd.h b/lib/utils_cmd.h index d00069c9..728ece23 100644 --- a/lib/utils_cmd.h +++ b/lib/utils_cmd.h | |||
@@ -20,7 +20,7 @@ typedef struct output output; | |||
20 | /** prototypes **/ | 20 | /** prototypes **/ |
21 | int cmd_run(const char *, output *, output *, int); | 21 | int cmd_run(const char *, output *, output *, int); |
22 | int cmd_run_array(char *const *, output *, output *, int); | 22 | int cmd_run_array(char *const *, output *, output *, int); |
23 | int cmd_file_read(char *, output *, int); | 23 | int cmd_file_read(const char *, output *, int); |
24 | 24 | ||
25 | /* only multi-threaded plugins need to bother with this */ | 25 | /* only multi-threaded plugins need to bother with this */ |
26 | void cmd_init(void); | 26 | void cmd_init(void); |