* lib/prototypes.h, libmisc/list.c: dup_list() and is_on_list() do

not change the members of the list they receive. Added const
	qualifiers.
This commit is contained in:
nekral-guest 2010-08-20 20:26:32 +00:00
parent fad23b25a1
commit 660ed49daf
3 changed files with 10 additions and 4 deletions

View File

@ -1,3 +1,9 @@
2010-08-20 Nicolas François <nicolas.francois@centraliens.net>
* lib/prototypes.h, libmisc/list.c: dup_list() and is_on_list() do
not change the members of the list they receive. Added const
qualifiers.
2010-08-20 Nicolas François <nicolas.francois@centraliens.net>
* src/usermod.c: Re-indent.

View File

@ -214,8 +214,8 @@ extern void setup_limits (const struct passwd *);
/* list.c */
extern /*@only@*/ /*@out@*/char **add_list (/*@returned@*/ /*@only@*/char **, const char *);
extern /*@only@*/ /*@out@*/char **del_list (/*@returned@*/ /*@only@*/char **, const char *);
extern /*@only@*/ /*@out@*/char **dup_list (char *const *);
extern bool is_on_list (char *const *list, const char *member);
extern /*@only@*/ /*@out@*/char **dup_list (const char *const *);
extern bool is_on_list (const char *const *list, const char *member);
extern /*@only@*/char **comma_to_list (const char *);
/* log.c */

View File

@ -141,7 +141,7 @@
return tmp;
}
/*@only@*/ /*@out@*/char **dup_list (char *const *list)
/*@only@*/ /*@out@*/char **dup_list (const char *const *list)
{
int i;
char **tmp;
@ -163,7 +163,7 @@
return tmp;
}
bool is_on_list (char *const *list, const char *member)
bool is_on_list (const char *const *list, const char *member)
{
assert (NULL != member);
assert (NULL != list);