summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorin2 <in2@63ad8ddf-47c3-0310-b6dd-a9e9d9715204>2003-05-15 16:27:23 +0800
committerin2 <in2@63ad8ddf-47c3-0310-b6dd-a9e9d9715204>2003-05-15 16:27:23 +0800
commit9efeebb36877b9afe475fa6df9ba1816ebbda926 (patch)
treee9de82dc6bf9c276b91252921e0aa121d51b6c53
parent6168edfac6562867f6941db0524a11033dc165cb (diff)
downloadpttbbs-9efeebb36877b9afe475fa6df9ba1816ebbda926.tar
pttbbs-9efeebb36877b9afe475fa6df9ba1816ebbda926.tar.gz
pttbbs-9efeebb36877b9afe475fa6df9ba1816ebbda926.tar.bz2
pttbbs-9efeebb36877b9afe475fa6df9ba1816ebbda926.tar.lz
pttbbs-9efeebb36877b9afe475fa6df9ba1816ebbda926.tar.xz
pttbbs-9efeebb36877b9afe475fa6df9ba1816ebbda926.tar.zst
pttbbs-9efeebb36877b9afe475fa6df9ba1816ebbda926.zip
warning free
git-svn-id: http://opensvn.csie.org/pttbbs/pttbbs/trunk/pttbbs@850 63ad8ddf-47c3-0310-b6dd-a9e9d9715204
-rw-r--r--util/mandex.c4
-rw-r--r--util/uhash_loader.c4
-rw-r--r--util/util_passwd.c3
-rw-r--r--util/util_record.c4
4 files changed, 9 insertions, 6 deletions
diff --git a/util/mandex.c b/util/mandex.c
index 1ca9494c..6088bc75 100644
--- a/util/mandex.c
+++ b/util/mandex.c
@@ -1,4 +1,4 @@
-/* $Id: mandex.c,v 1.8 2002/08/12 15:04:01 kcwu Exp $ */
+/* $Id: mandex.c,v 1.9 2003/05/15 08:27:23 in2 Exp $ */
/* 'mandex -h' to help */
@@ -154,7 +154,7 @@ mandex(level, num_header, fpath)
int main(int argc, char* argv[])
{
- boardheader_t *bptr;
+ boardheader_t *bptr = NULL;
DIR *dirp;
struct dirent *de;
int ch, n, place = 0, fd, i;
diff --git a/util/uhash_loader.c b/util/uhash_loader.c
index 5fadd48e..7d066ab9 100644
--- a/util/uhash_loader.c
+++ b/util/uhash_loader.c
@@ -1,6 +1,8 @@
-/* $Id: uhash_loader.c,v 1.3 2002/06/06 21:34:14 in2 Exp $ */
+/* $Id: uhash_loader.c,v 1.4 2003/05/15 08:27:23 in2 Exp $ */
/* standalone uhash loader -- jochang */
#include <stdio.h>
+#include <stdlib.h>
+#include <string.h>
#include <unistd.h>
#include <fcntl.h>
#include <ctype.h>
diff --git a/util/util_passwd.c b/util/util_passwd.c
index 17961d87..d7f1cea2 100644
--- a/util/util_passwd.c
+++ b/util/util_passwd.c
@@ -1,5 +1,6 @@
-/* $Id: util_passwd.c,v 1.3 2002/11/02 11:02:44 in2 Exp $ */
+/* $Id: util_passwd.c,v 1.4 2003/05/15 08:27:23 in2 Exp $ */
#include <stdio.h>
+#include <stdlib.h>
#include <string.h>
#include <fcntl.h>
#include <errno.h>
diff --git a/util/util_record.c b/util/util_record.c
index 98b6e43f..80a7ff56 100644
--- a/util/util_record.c
+++ b/util/util_record.c
@@ -1,4 +1,4 @@
-/* $Id: util_record.c,v 1.3 2002/11/02 11:02:44 in2 Exp $ */
+/* $Id: util_record.c,v 1.4 2003/05/15 08:27:23 in2 Exp $ */
#include <stdio.h>
#include <stdlib.h>
#include <errno.h>
@@ -135,7 +135,7 @@ int apply_record(char *fpath, int (*fptr)(), int size) {
if(!(fp = fopen(fpath, "r")))
return -1;
- while(fread(abuf, 1, size, fp) == size)
+ while(fread(abuf, 1, size, fp) == (unsigned)size)
if((*fptr) (abuf) == QUIT) {
fclose(fp);
return QUIT;