From f9c49b24dce71468e99209e76bdd17e7fe2d4408 Mon Sep 17 00:00:00 2001 From: Roland McGrath Date: Wed, 6 Oct 2004 22:11:54 +0000 Subject: [PATCH] 2004-10-06 Roland McGrath * file.c (sprintmode): Add const to return type. (sprintfstype): Likewise. * signal.c (printsiginfo): Add a const. --- file.c | 8 ++++---- signal.c | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/file.c b/file.c index 7d9e7aba..bbbebe8a 100644 --- a/file.c +++ b/file.c @@ -555,12 +555,12 @@ static const struct xlat modetypes[] = { { 0, NULL }, }; -static char * +static const char * sprintmode(mode) int mode; { static char buf[64]; - char *s; + const char *s; if ((mode & S_IFMT) == 0) s = ""; @@ -1437,13 +1437,13 @@ static const struct xlat fsmagic[] = { #ifndef SVR4 -static char * +static const char * sprintfstype(magic) int magic; { static char buf[32]; #ifdef LINUX - char *s; + const char *s; s = xlookup(fsmagic, magic); if (s) { diff --git a/signal.c b/signal.c index 657db238..e846f6c2 100644 --- a/signal.c +++ b/signal.c @@ -643,7 +643,7 @@ printsiginfo(sip, verbose) siginfo_t *sip; int verbose; { - char *code; + const char *code; if (sip->si_signo == 0) { tprintf ("{}"); -- 2.50.1