[label, entry] bugfix null ref in _strbuf_key_value_replace
authorHyoyoung Chang <hyoyoung.chang@samsung.com>
Fri, 17 Dec 2010 05:50:29 +0000 (14:50 +0900)
committerHyoyoung Chang <hyoyoung.chang@samsung.com>
Fri, 17 Dec 2010 05:50:29 +0000 (14:50 +0900)
src/lib/elm_entry.c
src/lib/elm_label.c

index a730c35..b8f5d60 100644 (file)
@@ -1737,11 +1737,9 @@ _strbuf_key_value_replace(Eina_Strbuf *srcbuf, char *key, const char *value, int
                replocater = curlocater + strlen(key) + 1;
 
                while (*replocater == ' ' || *replocater == '=')
-                          {
                  replocater++;
-                          }
 
-                while (replocater != NULL && *replocater != ' ' && *replocater != '>')
+                while (*replocater && *replocater != ' ' && *replocater != '>')
                   replocater++;
 
                if (replocater-curlocater > strlen(key)+1)
index b040803..a704449 100644 (file)
@@ -281,11 +281,9 @@ _strbuf_key_value_replace(Eina_Strbuf *srcbuf,
                   replocater = curlocater + strlen(key) + 1;
 
                   while (*replocater == ' ' || *replocater == '=')
-                    {
-                       replocater++;
-                    }
+                    replocater++;
 
-                  while (replocater != NULL && *replocater != ' ' && *replocater != '>')
+                  while (*replocater && *replocater != ' ' && *replocater != '>')
                     replocater++;
 
                   if (replocater - curlocater > strlen(key) + 1)