Hi all,

There's a typo in the conditional to check the exit condition in ascii_strcasecmp in share/utf8/charset.c. It checks for (!*s1 || !*s1) instead of (!*s1 || !*s2). Attached patch fixes this.

Note that the typo did not affect the result of the function as the loop is exited before changing s1 or s2 anyway.

The problem was found by cppcheck which is run automatically on the Debian sources. Results here: http://cppcheck.sourceforge.net/devinfo/daca2-cppcheck1.63/daca2.html

Best regards,
Robert
diff -Naur flac-1.3.0/src/share/utf8/charset.c flac-1.3.0-patched/src/share/utf8/charset.c
--- flac-1.3.0/src/share/utf8/charset.c	2013-04-30 10:47:38 +0000
+++ flac-1.3.0-patched/src/share/utf8/charset.c	2014-02-02 15:00:45 +0000
@@ -56,7 +56,7 @@
   char c1, c2;
 
   for (;; s1++, s2++) {
-    if (!*s1 || !*s1)
+    if (!*s1 || !*s2)
       break;
     if (*s1 == *s2)
       continue;
_______________________________________________
flac-dev mailing list
flac-dev@xiph.org
http://lists.xiph.org/mailman/listinfo/flac-dev

Reply via email to