]> rtime.felk.cvut.cz Git - frescor/ffmpeg.git/commitdiff
convert a if() into a switch() to ease addition of new tags to probe
authoraurel <aurel@9553f0bf-9b14-0410-a0b8-cfaf0461ba5b>
Mon, 22 Oct 2007 21:06:04 +0000 (21:06 +0000)
committeraurel <aurel@9553f0bf-9b14-0410-a0b8-cfaf0461ba5b>
Mon, 22 Oct 2007 21:06:04 +0000 (21:06 +0000)
git-svn-id: file:///var/local/repositories/ffmpeg/trunk@10843 9553f0bf-9b14-0410-a0b8-cfaf0461ba5b

libavformat/electronicarts.c

index 7cf15efd8b526ecd4690369cb81fbeaf29aad8fc..b4c14e0080543bdc890330d45092379627dc5da4 100644 (file)
@@ -227,12 +227,11 @@ static int process_ea_header(AVFormatContext *s) {
 
 static int ea_probe(AVProbeData *p)
 {
-    uint32_t tag;
-
-    tag = AV_RL32(&p->buf[0]);
-    if (tag == SCHl_TAG || tag == MVhd_TAG)
+    switch (AV_RL32(&p->buf[0])) {
+    case SCHl_TAG:
+    case MVhd_TAG:
         return AVPROBE_SCORE_MAX;
-
+    }
     return 0;
 }