• Andreas Rheinhardt's avatar
    avformat/matroskaenc: Simplify writing Void elements · 98a6c6ec
    Andreas Rheinhardt authored
    Reserving space in Matroska works by writing a Void element. And until
    now this worked as follows: The current position was recorded and the
    EBML ID as well as the length field written; then the new position was
    recorded to know how much more to write. Afterwards the actual writing
    has been performed via ffio_fill().
    
    But it is unnecessary to explicitly use the positions (obtained via
    avio_tell()) to find out how much still needs to be written, because the
    length of the ID and the length field are known. So rewrite the function
    to no longer use them.
    
    Also, given that ffio_fill() uses an int parameter and given that no
    current caller (and no sane future caller) will want to reserve several
    GB of space, make the size parameter of put_ebml_void() itself an int.
    Signed-off-by: 's avatarAndreas Rheinhardt <andreas.rheinhardt@gmail.com>
    98a6c6ec
Name
Last commit
Last update
compat Loading commit data...
doc Loading commit data...
ffbuild Loading commit data...
fftools Loading commit data...
libavcodec Loading commit data...
libavdevice Loading commit data...
libavfilter Loading commit data...
libavformat Loading commit data...
libavresample Loading commit data...
libavutil Loading commit data...
libpostproc Loading commit data...
libswresample Loading commit data...
libswscale Loading commit data...
presets Loading commit data...
tests Loading commit data...
tools Loading commit data...
.gitattributes Loading commit data...
.gitignore Loading commit data...
.mailmap Loading commit data...
.travis.yml Loading commit data...
CONTRIBUTING.md Loading commit data...
COPYING.GPLv2 Loading commit data...
COPYING.GPLv3 Loading commit data...
COPYING.LGPLv2.1 Loading commit data...
COPYING.LGPLv3 Loading commit data...
CREDITS Loading commit data...
Changelog Loading commit data...
INSTALL.md Loading commit data...
LICENSE.md Loading commit data...
MAINTAINERS Loading commit data...
Makefile Loading commit data...
README.md Loading commit data...
RELEASE Loading commit data...
configure Loading commit data...