callback.c: check for negative xfered size

Signed-off-by: Andrew Gregory <andrew.gregory.8@gmail.com>
Signed-off-by: Allan McRae <allan@archlinux.org>
This commit is contained in:
Andrew Gregory 2013-10-24 09:22:53 -04:00 committed by Allan McRae
parent b82a0d83ce
commit 1c5b94e6bb
1 changed files with 1 additions and 1 deletions

View File

@ -632,7 +632,7 @@ void cb_dl_progress(const char *filename, off_t file_xfered, off_t file_total)
}
/* bogus values : stop here */
if(xfered > total) {
if(xfered > total || xfered < 0) {
return;
}