]> git.eshelyaron.com Git - emacs.git/commitdiff
(read_score): Fix type of second parameter
authorAndreas Schwab <schwab@suse.de>
Sun, 14 Apr 2002 01:02:53 +0000 (01:02 +0000)
committerAndreas Schwab <schwab@suse.de>
Sun, 14 Apr 2002 01:02:53 +0000 (01:02 +0000)
of getdelim to be of type size_t instead of int.  Use 0 instead of
ESUCCES.

lib-src/ChangeLog
lib-src/update-game-score.c

index e480cf1ff47f6242a70bd4cc75e8d21ffcec89f6..51534cd53ab986cbc98c788d28c4e270281b74f3 100644 (file)
@@ -1,3 +1,9 @@
+2002-04-14  Andreas Schwab  <schwab@suse.de>
+
+       * update-game-score.c (read_score): Fix type of second parameter
+       of getdelim to be of type size_t instead of int.  Use 0 instead of
+       ESUCCES.
+
 2002-04-10  Colin Walters  <walters@verbum.org>
 
        * update-game-score.c: (toplevel): Include stdarg.h.
index 31d3737d95e268ef2372877fc3ecd1843fa1ff7b..2f49197a6dccc6c7379b2985b19142ef428ffecc 100644 (file)
@@ -249,7 +249,7 @@ read_score(FILE *f, struct score_entry *score)
   ungetc(c, f);
 #ifdef HAVE_GETDELIM
   {
-    int count = 0;
+    size_t count = 0;
     if (getdelim(&score->username, &count, ' ', f) < 1
        || score->username == NULL)
       return -1;
@@ -279,9 +279,9 @@ read_score(FILE *f, struct score_entry *score)
 #endif
 #ifdef HAVE_GETLINE
   score->data = NULL;
-  errno = ESUCCES;
+  errno = 0;
   {
-    int len;
+    size_t len;
     if (getline(&score->data, &len, f) < 0)
       return -1;
     score->data[strlen(score->data)-1] = '\0';