Commit Diff


commit - a63e71fc7d1511753e88666b6d0bc879bb0006ed
commit + 47cb899ab91a8049fcdc720deca7ee2f7a8fad3b
blob - 11a0b93b837f412e3b4e9f76a0052c134ac8ec9d
blob + 1a0dd01738408da65ed6a4c4b43a1cab74d217b7
--- FICS/makerank.c
+++ FICS/makerank.c
@@ -45,7 +45,7 @@ GetPlayerInfo(char *fileName, ENTRY *e)
 	    fgets(line, sizeof line, fp) == NULL ||
 	    feof(fp)) {
 		if (fp)
-			fclose(fp);
+			(void) fclose(fp);
 		return 0;
 	}
 
@@ -55,7 +55,7 @@ GetPlayerInfo(char *fileName, ENTRY *e)
 		if (fgets(line, sizeof line, fp) == NULL ||
 		    sscanf(line, "%19s", e->name) != 1) {
 			warnx("%s: fgets() or sscanf() error", __func__);
-			fclose(fp);
+			(void) fclose(fp);
 			return 0;
 		} else if (fgets(line, sizeof line, fp) == NULL ||
 			   fgets(line, sizeof line, fp) == NULL ||
@@ -78,7 +78,7 @@ GetPlayerInfo(char *fileName, ENTRY *e)
 		    &(e->r[3].rating)) != 8) {
 			fprintf(stderr, "OOPS: couldn't parse player file %s."
 			    "\n", fileName);
-			fclose(fp);
+			(void) fclose(fp);
 			return 0;
 		}
 
@@ -92,7 +92,7 @@ GetPlayerInfo(char *fileName, ENTRY *e)
 
 			if (sscanf(line, "%19s", field) != 1) {
 				warnx("%s: sscanf() error", __func__);
-				fclose(fp);
+				(void) fclose(fp);
 				return 0;
 			}
 
@@ -100,7 +100,7 @@ GetPlayerInfo(char *fileName, ENTRY *e)
 				if (sscanf(line, "%*s %29s", NameWithCase) != 1) {
 					warnx("%s: expected name with case",
 					    __func__);
-					fclose(fp);
+					(void) fclose(fp);
 					return 0;
 				}