summaryrefslogtreecommitdiff
path: root/test/interactive-helper/testextract.cc
diff options
context:
space:
mode:
Diffstat (limited to 'test/interactive-helper/testextract.cc')
-rw-r--r--test/interactive-helper/testextract.cc3
1 files changed, 2 insertions, 1 deletions
diff --git a/test/interactive-helper/testextract.cc b/test/interactive-helper/testextract.cc
index f7ddb72f0..8dfe68fc9 100644
--- a/test/interactive-helper/testextract.cc
+++ b/test/interactive-helper/testextract.cc
@@ -66,7 +66,8 @@ bool Go(int argc,char *argv[])
while (feof(F) == 0)
{
char Line[300];
- fgets(Line,sizeof(Line),F);
+ if (fgets(Line,sizeof(Line),F) == NULL)
+ return false;
Itm.Name = _strstrip(Line);
Itm.Type = pkgDirStream::Item::File;
if (Line[strlen(Line)-1] == '/')