/*
- * Sherlock Library -- Fast Buffered I/O
+ * UCW Library -- Fast Buffered I/O
*
- * (c) 1997--2004 Martin Mares <mj@ucw.cz>
+ * (c) 1997--2005 Martin Mares <mj@ucw.cz>
*
* This software may be freely distributed and used according to the terms
* of the GNU Lesser General Public License.
bsetpos(f, 0);
}
-void
-bskip(struct fastbuf *f, uns len)
+int
+bskip_slow(struct fastbuf *f, uns len)
{
while (len)
{
byte *buf;
uns l = bdirect_read_prepare(f, &buf);
+ if (!l)
+ return 0;
l = MIN(l, len);
bdirect_read_commit(f, buf+l);
len -= l;
}
+ return 1;
}
sh_off_t