From e76a4a8dc605651128a2ed927d93fc12f68ff6b0 Mon Sep 17 00:00:00 2001 From: Ian C Date: Wed, 10 May 2017 09:02:14 +0000 Subject: Fixed warning about fgets(). --- dbox.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/dbox.c b/dbox.c index 53a905c..aadacb7 100644 --- a/dbox.c +++ b/dbox.c @@ -221,9 +221,7 @@ static const char *GetLine(FILE *p_fp) static char s[1024]; size_t l; - fgets(s, sizeof s, p_fp); - - if (feof(p_fp)) + if (!fgets(s, sizeof s, p_fp)) { return NULL; } -- cgit v1.2.3