diff --git a/libisofs/trunk/libisofs/ecma119.c b/libisofs/trunk/libisofs/ecma119.c index 1e9c07e7..9bcd1932 100644 --- a/libisofs/trunk/libisofs/ecma119.c +++ b/libisofs/trunk/libisofs/ecma119.c @@ -876,7 +876,7 @@ bs_read_block(struct burn_source *bs) t->curblock++; return t->block_size; } - return -1; + return 0; } if (t->state_data_valid) write_data_chunk(t, t->buffer); @@ -898,8 +898,8 @@ bs_read(struct burn_source *bs, unsigned char *buf, int size) /* we need to read next block */ t->bytes_read = 0; ret = bs_read_block(bs); - if (ret < 0) - return -1; + if (ret <= 0) + return ret; } int bytes_to_read = 2048 - t->bytes_read;