diff options
author | Thomas White <taw@bitwiz.org.uk> | 2012-07-20 15:01:48 -0400 |
---|---|---|
committer | Thomas White <taw@bitwiz.org.uk> | 2012-07-20 15:01:59 -0400 |
commit | 87f6f2a16d642df8f846f432151cb803b766b3cb (patch) | |
tree | 9031babb8331d6476c9c3c2bc97f635cce05b799 /src | |
parent | c78895d1964ade09c9a006d4d600e592d773e542 (diff) |
Tidy up the exit path from run_work()
Diffstat (limited to 'src')
-rw-r--r-- | src/im-sandbox.c | 13 |
1 files changed, 5 insertions, 8 deletions
diff --git a/src/im-sandbox.c b/src/im-sandbox.c index 8187612d..eb823683 100644 --- a/src/im-sandbox.c +++ b/src/im-sandbox.c @@ -345,15 +345,12 @@ static void run_work(const struct index_args *iargs, line = malloc(1024*sizeof(char)); rval = fgets(line, 1023, fh); if ( rval == NULL ) { + + ERROR("Read error!\n"); free(line); - if ( feof(fh) ) { - allDone = 1; - STATUS("Exiting!\n"); - continue; - } else { - ERROR("Read error!\n"); - break; - } + allDone = 1; + continue; + } chomp(line); |