Most EBML masters are much smaller than IO_BUFFER_SIZE and thus the size
can be updated. This makes parsing the resulting files easier.
Originally committed as revision 22197 to svn://svn.ffmpeg.org/ffmpeg/trunk
{
int64_t pos = url_ftell(pb);
- // leave the unknown size for masters when streaming
- if (url_is_streamed(pb))
+ if (url_fseek(pb, master.pos - master.sizebytes, SEEK_SET) < 0)
return;
-
- url_fseek(pb, master.pos - master.sizebytes, SEEK_SET);
put_ebml_num(pb, pos - master.pos, master.sizebytes);
url_fseek(pb, pos, SEEK_SET);
}