diff options
author | Larbi Joubala <larbi.joubala@resonate-mp4.com> | 2009-05-23 07:17:17 +0000 |
---|---|---|
committer | Baptiste Coudurier <baptiste.coudurier@gmail.com> | 2009-05-23 07:17:17 +0000 |
commit | 606d48cee1a5bdc3affbc91cbe01cd90f790d26a (patch) | |
tree | 7bab66391b27f3d16b60cbecb27b978e45d3413a /libavformat/movenc.c | |
parent | 84df78b476ca127e104195c5f90e0546cb2e70c9 (diff) | |
download | ffmpeg-606d48cee1a5bdc3affbc91cbe01cd90f790d26a.tar.gz |
fix hdlr descr in mp4 which use c string, patch by Larbi Joubala, larbi dot joubala at resonate-mp4 dot com
Originally committed as revision 18911 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavformat/movenc.c')
-rw-r--r-- | libavformat/movenc.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/libavformat/movenc.c b/libavformat/movenc.c index 3abe388588..7a2ce2526a 100644 --- a/libavformat/movenc.c +++ b/libavformat/movenc.c @@ -1013,8 +1013,11 @@ static int mov_write_hdlr_tag(ByteIOContext *pb, MOVTrack *track) put_be32(pb ,0); /* reserved */ put_be32(pb ,0); /* reserved */ put_be32(pb ,0); /* reserved */ - put_byte(pb, strlen(descr)); /* string counter */ + if (!track || track->mode == MODE_MOV) + put_byte(pb, strlen(descr)); /* pascal string */ put_buffer(pb, descr, strlen(descr)); /* handler description */ + if (track && track->mode != MODE_MOV) + put_byte(pb, 0); /* c string */ return updateSize(pb, pos); } |