Change a couple strstr() to strchr()
authorBehdad Esfahbod <behdad@behdad.org>
Wed, 15 Jun 2011 13:33:52 +0000 (09:33 -0400)
committerBehdad Esfahbod <behdad@behdad.org>
Wed, 15 Jun 2011 13:33:52 +0000 (09:33 -0400)
src/hb-ot-tag.cc

index 0ed0c83..0ce635a 100644 (file)
@@ -586,10 +586,10 @@ lang_compare_first_component (const char *a,
   unsigned int da, db;
   const char *p;
 
-  p = strstr (a, "-");
+  p = strchr (a, '-');
   da = p ? (unsigned int) (p - a) : strlen (a);
 
-  p = strstr (b, "-");
+  p = strchr (b, '-');
   db = p ? (unsigned int) (p - b) : strlen (b);
 
   return strncmp (a, b, MAX (da, db));