stream: don't set EOF flag in stream implementations

EOF should be set when reading more data fails. The stream
implementations have nothing to say here and should behave correctly
when trying to read when EOF was actually read.

Even when seeking, a correct EOF flag should be guaranteed. stream_seek()
(or actually stream_seek_long()) calls stream_fill_buffer() at least
once, which also updates the EOF flag.
This commit is contained in:
wm4
2013-06-06 20:40:02 +02:00
parent 1c35794efd
commit 0d5e6084ae
7 changed files with 1 additions and 13 deletions

View File

@@ -88,7 +88,6 @@ static int control(stream_t *s, int cmd, void *arg) {
static int seek(stream_t *s,int64_t newpos) {
s->pos = newpos;
if(smbc_lseek(s->fd,s->pos,SEEK_SET)<0) {
s->eof=1;
return 0;
}
return 1;