diff flacdec.c @ 4760:9a8c5a8c64ea libavformat

seek backwards 4 bytes if 'fLaC' marker is not found
author jbr
date Sat, 21 Mar 2009 00:49:14 +0000
parents 478a7c56266a
children 3aabdadf9d5f
line wrap: on
line diff
--- a/flacdec.c	Fri Mar 20 17:23:45 2009 +0000
+++ b/flacdec.c	Sat Mar 21 00:49:14 2009 +0000
@@ -50,8 +50,10 @@
     }
 
     /* if fLaC marker is not found, assume there is no header */
-    if (get_le32(s->pb) != MKTAG('f','L','a','C'))
+    if (get_le32(s->pb) != MKTAG('f','L','a','C')) {
+        url_fseek(s->pb, -4, SEEK_CUR);
         return 0;
+    }
 
     /* process metadata blocks */
     while (!url_feof(s->pb) && !metadata_last) {