diff --git a/vfs/ChangeLog b/vfs/ChangeLog index 0867c0b6b..4648fd433 100644 --- a/vfs/ChangeLog +++ b/vfs/ChangeLog @@ -6,6 +6,14 @@ (login_server): Constify netrcpass parameter. (is_same_dir): Constify path parameter. + * samba/lib/charset.c (cp_850): Make const array. + (cp_932): Ditto. + (codepage_p): Likewise. + * samba/lib/debug.c (priority_map): Make const array. + * samba/lib/username.c (get_home_dir): Make pass auto. + * samba/lib/util.c (become_daemon): Commented out. + (yesno): Likewise. + 2002-01-24 Pavel Roskin * cpio.c: Don't include glib.h directly. diff --git a/vfs/samba/lib/charset.c b/vfs/samba/lib/charset.c index fc2924a15..97319ae93 100644 --- a/vfs/samba/lib/charset.c +++ b/vfs/samba/lib/charset.c @@ -30,7 +30,7 @@ extern int DEBUGLEVEL; #if !defined(KANJI) /* lower->upper mapping for IBM Code Page 850 - MS-DOS Latin 1 */ -unsigned char cp_850[][4] = { +unsigned char const cp_850[][4] = { /* dec col/row oct hex description */ /* 133 08/05 205 85 a grave */ /* 183 11/07 267 B7 A grave */ {0x85,0xB7,1,1}, @@ -98,7 +98,7 @@ unsigned char cp_850[][4] = { }; #else /* KANJI */ /* lower->upper mapping for IBM Code Page 932 - MS-DOS Japanese SJIS */ -unsigned char cp_932[][4] = { +unsigned char const cp_932[][4] = { {0,0,0,0} }; #endif /* KANJI */ @@ -182,7 +182,7 @@ void charset_initialise(void) load the client codepage. ****************************************************************************/ -typedef unsigned char (*codepage_p)[4]; +typedef const unsigned char (*codepage_p)[4]; static codepage_p load_client_codepage( int client_codepage ) { diff --git a/vfs/samba/lib/debug.c b/vfs/samba/lib/debug.c index 94c3d9af9..9564ae1a5 100644 --- a/vfs/samba/lib/debug.c +++ b/vfs/samba/lib/debug.c @@ -356,7 +356,7 @@ va_dcl * note that not all DEBUG(0, ...) calls are * necessarily errors */ - static int priority_map[] = { + static int const priority_map[] = { LOG_ERR, /* 0 */ LOG_WARNING, /* 1 */ LOG_NOTICE, /* 2 */ diff --git a/vfs/samba/lib/username.c b/vfs/samba/lib/username.c index f04314ab3..52ce1ac0c 100644 --- a/vfs/samba/lib/username.c +++ b/vfs/samba/lib/username.c @@ -31,7 +31,7 @@ get a users home directory. ****************************************************************************/ char *get_home_dir(char *user) { - static struct passwd *pass; + struct passwd *pass; pass = Get_Pwnam(user, False); diff --git a/vfs/samba/lib/util.c b/vfs/samba/lib/util.c index 3d03e83fa..03e08cab4 100644 --- a/vfs/samba/lib/util.c +++ b/vfs/samba/lib/util.c @@ -1550,6 +1550,7 @@ BOOL mask_match(char *str, char *regexp, int case_sig,BOOL trans2) return matched; } +#if 0 /**************************************************************************** become a daemon, discarding the controlling terminal ****************************************************************************/ @@ -1593,6 +1594,7 @@ BOOL yesno(char *p) return(False); } +#endif /**************************************************************************** set the length of a file from a filedescriptor.