X-Git-Url: http://mj.ucw.cz/gitweb/?a=blobdiff_plain;ds=sidebyside;f=lib%2Ffastbuf.c;h=b7be624b5645d5ac34e1e52ca83b1ce2a951be62;hb=cd5b7ea487ab7692635ba7eca98fcb55f6d996a7;hp=115719422b8844875edefb015f61170297c0494a;hpb=e38455f76749ff06f64649871ed5e33302389948;p=libucw.git diff --git a/lib/fastbuf.c b/lib/fastbuf.c index 11571942..b7be624b 100644 --- a/lib/fastbuf.c +++ b/lib/fastbuf.c @@ -290,7 +290,7 @@ bbcopy_slow(struct fastbuf *f, struct fastbuf *t, uns l) uns favail, tavail, n; favail = bdirect_read_prepare(f, &fptr); - if (favail == (uns)EOF) + if (!favail) die("bbcopy: source exhausted"); tavail = bdirect_write_prepare(t, &tptr); n = MIN(l, favail);