OSDN Git Service

avformat/electronicarts: detect endianness by comparing sizes instead of using an...
authorMichael Niedermayer <michaelni@gmx.at>
Sat, 21 Dec 2013 13:09:45 +0000 (14:09 +0100)
committerMichael Niedermayer <michaelni@gmx.at>
Sat, 21 Dec 2013 13:09:45 +0000 (14:09 +0100)
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
libavformat/electronicarts.c

index d01883f..4ba0fa0 100644 (file)
@@ -357,7 +357,7 @@ static int process_ea_header(AVFormatContext *s)
         blockid = avio_rl32(pb);
         size    = avio_rl32(pb);
         if (i == 0)
-            ea->big_endian = size > 0x000FFFFF;
+            ea->big_endian = size > av_bswap32(size);
         if (ea->big_endian)
             size = av_bswap32(size);