From 3d2b7f2ec131a2de44c9dc75bd897f210a91805d Mon Sep 17 00:00:00 2001 From: Jihoon Kim Date: Wed, 27 Nov 2013 09:31:26 +0900 Subject: [PATCH] edje_entry: fix out-ouf-bounds issue in _edje_entry_imf_event_preedit_changed_cb The maximum index of tagname is 7, and preedit_type_size is equal to 8. Checking "attr->preedit_type <= preedit_type_size" implies that the value of "attr->preedit_type" may be up to 8 This patch fixes CID 1039308 --- src/lib/edje/edje_entry.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/lib/edje/edje_entry.c b/src/lib/edje/edje_entry.c index e8afc554dd..4c5ce65ebd 100644 --- a/src/lib/edje/edje_entry.c +++ b/src/lib/edje/edje_entry.c @@ -3999,7 +3999,7 @@ _edje_entry_imf_event_preedit_changed_cb(void *data, Ecore_IMF_Context *ctx EINA { EINA_LIST_FOREACH(attrs, l, attr) { - if (attr->preedit_type <= preedit_type_size && + if (attr->preedit_type < preedit_type_size && tagname[attr->preedit_type]) { preedit_attr_str = eina_strbuf_new();