Correctly reset the ANS file number when restarting Uemis download

If we ran out of space on the Uemis SDA during download and the user
unmounted, unplugged and replugged the SDA, we need to take care to
correctly reset the file number we use for finding the correct ANS file.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
Dirk Hohndel 2012-11-19 15:09:50 -08:00
parent ddebdc0982
commit 4e02f5f3a3

View file

@ -128,11 +128,12 @@ static gboolean uemis_init(const char *path)
if (sscanf(tmp + 1, "%d", &filenr) != 1)
return FALSE;
}
#if UEMIS_DEBUG > 1
else {
filenr = 0;
#if UEMIS_DEBUG > 1
fprintf(debugfile, "::r req.txt skipped as there were fewer than 5 bytes\n");
}
#endif
}
close (reqtxt_file);
/* It would be nice if we could simply go back to the first set of