From: Andre Noll Date: Sun, 31 Dec 2017 22:37:16 +0000 (+0100) Subject: server: Make argument of user_list_init() constant. X-Git-Tag: v0.6.2~4^2~11 X-Git-Url: http://git.tuebingen.mpg.de/?p=paraslash.git;a=commitdiff_plain;h=0e5dedaa7f494adcd2970c301343fc04933fae72;hp=ac93cb364106bbaa88bf0d0852981a872166e6a9 server: Make argument of user_list_init() constant. The function does not modify the memory pointed to by user_list_file. --- diff --git a/user_list.c b/user_list.c index 18b489b9..030865fa 100644 --- a/user_list.c +++ b/user_list.c @@ -67,7 +67,7 @@ void user_list_deplete(void) * * This function either succeeds or calls exit(3). */ -void user_list_init(char *user_list_file) +void user_list_init(const char *user_list_file) { int ret = -E_USERLIST; FILE *file_ptr = fopen(user_list_file, "r"); diff --git a/user_list.h b/user_list.h index 3bc98f68..1cb94764 100644 --- a/user_list.h +++ b/user_list.h @@ -32,6 +32,6 @@ struct user { unsigned int perms; }; -void user_list_init(char *user_list_file); +void user_list_init(const char *user_list_file); void user_list_deplete(void); const struct user *user_list_lookup(const char *name);