diff img2.c @ 530:c7219ac0b694 libavformat

10l
author michael
date Wed, 22 Sep 2004 21:25:09 +0000
parents 7c8687cb7f27
children 955ca987adbd
line wrap: on
line diff
--- a/img2.c	Wed Sep 22 20:01:56 2004 +0000
+++ b/img2.c	Wed Sep 22 21:25:09 2004 +0000
@@ -46,8 +46,9 @@
 
 static enum CodecID av_str2id(const IdStrMap *tags, const char *str)
 {
-    while(*str && *str!='.') str++;
-    if(*str) str++;
+    str= strrchr(str, '.');
+    if(!str) return CODEC_ID_NONE;
+    str++;
 
     while (tags->id) {
         int i;