From 9518a6443cad777820fa42e32ab5950a52596600 Mon Sep 17 00:00:00 2001 From: Hyoyoung Chang Date: Fri, 17 Dec 2010 14:50:29 +0900 Subject: [PATCH] [label, entry] bugfix null ref in _strbuf_key_value_replace --- src/lib/elm_entry.c | 4 +--- src/lib/elm_label.c | 6 ++---- 2 files changed, 3 insertions(+), 7 deletions(-) diff --git a/src/lib/elm_entry.c b/src/lib/elm_entry.c index a730c35..b8f5d60 100644 --- a/src/lib/elm_entry.c +++ b/src/lib/elm_entry.c @@ -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) diff --git a/src/lib/elm_label.c b/src/lib/elm_label.c index b040803..a704449 100644 --- a/src/lib/elm_label.c +++ b/src/lib/elm_label.c @@ -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) -- 2.7.4