From: Evan Hunt Date: Wed, 15 Jan 2014 17:35:44 +0000 (-0800) Subject: [master] address compiler warnings X-Git-Tag: v9.10.0a2~86 X-Git-Url: http://git.ipfire.org/gitweb/?a=commitdiff_plain;h=e4f484b7b79e6f9238a2d9e807cb9933f9052668;p=thirdparty%2Fbind9.git [master] address compiler warnings --- diff --git a/lib/isc/tm.c b/lib/isc/tm.c index c14d36d656d..9f19f0727c8 100644 --- a/lib/isc/tm.c +++ b/lib/isc/tm.c @@ -58,6 +58,7 @@ #include #include +#include /* * Portable conversion routines for struct tm, replacing @@ -148,7 +149,7 @@ isc_tm_timegm(struct tm *tm) { char * isc_tm_strptime(const char *buf, const char *fmt, struct tm *tm) { - char c; + char c, *ret; const char *bp; size_t len = 0; int alt_format, i, split_year = 0; @@ -160,8 +161,8 @@ isc_tm_strptime(const char *buf, const char *fmt, struct tm *tm) { alt_format = 0; /* Eat up white-space. */ - if (isspace(c)) { - while (isspace(*bp)) + if (isspace((int) c)) { + while (isspace((int) *bp)) bp++; fmt++; @@ -426,7 +427,7 @@ literal: case 'n': /* Any kind of white-space. */ case 't': LEGAL_ALT(0); - while (isspace(*bp)) + while (isspace((int) *bp)) bp++; break; @@ -439,5 +440,6 @@ literal: } /* LINTED functional specification */ - return ((char *)bp); + DE_CONST(bp, ret); + return (ret); }