From: Ian Jackson Date: Tue, 5 Jul 2022 11:43:54 +0000 (+0100) Subject: fix warnings X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~ijackson/git?a=commitdiff_plain;h=429a748a18b45bcb7d57bb67893006bac92de423;p=nntp-merge-chiark.git fix warnings --- diff --git a/Makefile b/Makefile index ae8db6d..2b3767e 100644 --- a/Makefile +++ b/Makefile @@ -1,4 +1,4 @@ -CFLAGS= -Wall -Wwrite-strings -Wpointer-arith -Wnested-externs \ +CFLAGS= -Wall -Wwrite-strings -Wpointer-arith -Wnested-externs -Wno-format-overflow \ -Wmissing-declarations -Wmissing-prototypes -O3 -g # -DDEBUG LDFLAGS= -s diff --git a/main.c b/main.c index ff798f8..439a688 100644 --- a/main.c +++ b/main.c @@ -43,7 +43,7 @@ int stripcommand(char *buf) { void die(const char *msg) { int e; e= errno; - printf("400 server failure: %s - %s\r\n",msg,strerror(errno)); + printf("400 server failure: %s - %s\r\n",msg,strerror(e)); exit(0); } diff --git a/nnrpwrap.c b/nnrpwrap.c index 8b144bf..1e4c620 100644 --- a/nnrpwrap.c +++ b/nnrpwrap.c @@ -29,7 +29,8 @@ int main(int argc, char **argv) { char responsebuf[300]; char sesamebuf[MAX_SECRET*2+100]; struct sockaddr_in peername; - int c, namesize, n, l; + int c, n, l; + socklen_t namesize; struct MD5Context md5ctx; FILE *file; unsigned long ul; diff --git a/nyxpostrun.c b/nyxpostrun.c index b7e0c31..6978d90 100644 --- a/nyxpostrun.c +++ b/nyxpostrun.c @@ -1,5 +1,6 @@ #include #include +#include int main(int argc, char **argv) { int g; g= getegid();