diff options
author | Jee-Yong Um <jc9.um@samsung.com> | 2016-03-29 17:35:04 +0900 |
---|---|---|
committer | Jean-Philippe Andre <jp.andre@samsung.com> | 2016-03-29 17:35:05 +0900 |
commit | e260f23c94bbc8d5175337e1a1a50fe5d97ded7e (patch) | |
tree | e426799dd11a1c9ae3f1b0c2214bd848f9a39456 | |
parent | 32c136d84c3c43eccc2c6289aed065d9f30b589a (diff) | |
download | efl-e260f23c94bbc8d5175337e1a1a50fe5d97ded7e.tar.gz |
edje_cc: fix parsing error when some keywords are used as part name
Summary:
Some keywords cause parsing error when they are used as part name.
For example,
group { "some_group";
parts {
box { "box";
}
}
}
The part name "box" should be processed by wildcard handler,
but this is pushed into stack. (collections.group.parts.part.box ...)
This patch pushes token into stack only when it doesn't have quotes.
@fix
Reviewers: cedric, raster, jpeg
Reviewed By: jpeg
Subscribers: jpeg
Differential Revision: https://phab.enlightenment.org/D3841
-rw-r--r-- | src/bin/edje/edje_cc_parse.c | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/src/bin/edje/edje_cc_parse.c b/src/bin/edje/edje_cc_parse.c index 31eab3245b..542079a689 100644 --- a/src/bin/edje/edje_cc_parse.c +++ b/src/bin/edje/edje_cc_parse.c @@ -185,14 +185,17 @@ static void new_object(void) { const char *id; - New_Object_Handler *oh; + New_Object_Handler *oh = NULL; New_Statement_Handler *sh; fill_object_statement_hashes(); id = stack_id(); - oh = eina_hash_find(_new_object_hash, id); - if (!oh) - oh = eina_hash_find(_new_object_short_hash, id); + if (!had_quote) + { + oh = eina_hash_find(_new_object_hash, id); + if (!oh) + oh = eina_hash_find(_new_object_short_hash, id); + } if (oh) { if (oh->func) oh->func(); |