diff options
author | Kinga Stefaniuk <kinga.stefaniuk@intel.com> | 2024-05-07 05:38:55 +0200 |
---|---|---|
committer | Mariusz Tkaczyk <mariusz.tkaczyk@linux.intel.com> | 2024-05-14 11:07:27 +0200 |
commit | b0f4e8e30f38d83f7e3f53d01d72d4cb3b4d42d7 (patch) | |
tree | 2adf313972e469ffee2c9a051ef41c9c7af3cc1c /util.c | |
parent | tests/23rdev-lifetime: fix a typo (diff) | |
download | mdadm-b0f4e8e30f38d83f7e3f53d01d72d4cb3b4d42d7.tar.xz mdadm-b0f4e8e30f38d83f7e3f53d01d72d4cb3b4d42d7.zip |
util.c: change devnm to const in mdmon functions
Devnm shall not be changed inside mdmon_running()
and mdmon_pid() functions, change this parameter to const.
Signed-off-by: Kinga Stefaniuk <kinga.stefaniuk@intel.com>
Signed-off-by: Mariusz Tkaczyk <mariusz.tkaczyk@linux.intel.com>
Diffstat (limited to 'util.c')
-rw-r--r-- | util.c | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -1902,7 +1902,7 @@ unsigned long long min_recovery_start(struct mdinfo *array) return recovery_start; } -int mdmon_pid(char *devnm) +int mdmon_pid(const char *devnm) { char path[100]; char pid[10]; @@ -1922,7 +1922,7 @@ int mdmon_pid(char *devnm) return atoi(pid); } -int mdmon_running(char *devnm) +int mdmon_running(const char *devnm) { int pid = mdmon_pid(devnm); if (pid <= 0) |