diff options
author | Reimar Döffinger <Reimar.Doeffinger@gmx.de> | 2010-01-30 21:54:06 +0000 |
---|---|---|
committer | Reimar Döffinger <Reimar.Doeffinger@gmx.de> | 2010-01-30 21:54:06 +0000 |
commit | 1c90d2985d5f4ca5dd74459712109b7438e4c9bf (patch) | |
tree | 53f8c6869b2a69b5b0152d47c7bac443a4246425 /libavformat/isom.c | |
parent | 832ec42858430fc9c949fd9bcbac2a8e8e192ee2 (diff) | |
download | ffmpeg-1c90d2985d5f4ca5dd74459712109b7438e4c9bf.tar.gz |
Always consider the mov language code as 4 bytes fixed size and change the
function declaration to reflect this.
Originally committed as revision 21558 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavformat/isom.c')
-rw-r--r-- | libavformat/isom.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/libavformat/isom.c b/libavformat/isom.c index e54a5c9686..62daed08af 100644 --- a/libavformat/isom.c +++ b/libavformat/isom.c @@ -266,7 +266,7 @@ static const char * const mov_mdhd_language_map[] = { "cat", "lat", "que", "grn", "aym", "tat", "uig", "dzo", "jav" }; -int ff_mov_iso639_to_lang(const char *lang, int mp4) +int ff_mov_iso639_to_lang(const char lang[4], int mp4) { int i, code = 0; @@ -293,9 +293,10 @@ int ff_mov_iso639_to_lang(const char *lang, int mp4) return code; } -int ff_mov_lang_to_iso639(unsigned code, char *to) +int ff_mov_lang_to_iso639(unsigned code, char to[4]) { int i; + memset(to, 0, 4); /* is it the mangled iso code? */ /* see http://www.geocities.com/xhelmboyx/quicktime/formats/mp4-layout.txt */ if (code > 138) { |