]> git.ipfire.org Git - thirdparty/samba.git/commitdiff
s3:smbd: make globals in utmp.c static const
authorStefan Metzmacher <metze@samba.org>
Thu, 8 Jan 2009 07:51:41 +0000 (08:51 +0100)
committerStefan Metzmacher <metze@samba.org>
Thu, 8 Jan 2009 11:22:18 +0000 (12:22 +0100)
const char *foo, means a non-const pointer to
a const char.

const char * const foo, means a const pointer to
a const char.

char * const foo, would mean a const pointer to
a non-const char.

metze

source3/smbd/utmp.c

index af947ef4620fd29cf460e82fcec0deadf01248de..74774054e855d8ce04add9edb5f386ada7377e84 100644 (file)
@@ -142,7 +142,7 @@ void sys_utmp_yield(const char *username, const char *hostname,
 
 #ifdef HAVE_UTMPX_H
 
-static const char *ux_pathname =
+static const char * const ux_pathname =
 # if defined (UTMPX_FILE)
        UTMPX_FILE ;
 # elif defined (_UTMPX_FILE)
@@ -153,7 +153,7 @@ static const char *ux_pathname =
        "" ;
 # endif
 
-static const char *wx_pathname =
+static const char * const wx_pathname =
 # if defined (WTMPX_FILE)
        WTMPX_FILE ;
 # elif defined (_WTMPX_FILE)
@@ -166,7 +166,7 @@ static const char *wx_pathname =
 
 #endif /* HAVE_UTMPX_H */
 
-static const char *ut_pathname =
+static const char * const ut_pathname =
 # if defined (UTMP_FILE)
        UTMP_FILE ;
 # elif defined (_UTMP_FILE)
@@ -177,7 +177,7 @@ static const char *ut_pathname =
        "" ;
 # endif
 
-static const char *wt_pathname =
+static const char * const wt_pathname =
 # if defined (WTMP_FILE)
        WTMP_FILE ;
 # elif defined (_WTMP_FILE)