diff options
author | Chris Michael <cp.michael@samsung.com> | 2015-06-25 14:55:44 -0400 |
---|---|---|
committer | Chris Michael <cp.michael@samsung.com> | 2015-06-25 14:56:48 -0400 |
commit | 6949d1193eb7f3f7d9218157e78cdf1de5ba8c23 (patch) | |
tree | 91a7624d3a2b9966f0bfe3f0b8afb063b9b99aa2 /src/bin/edje | |
parent | cbc726ac56040ea3353f2404274836ec1b9a3a32 (diff) |
edje_cc: Fix dereference null return value
Summary: Fix Coverity CID1308232 which reports that we may be passing
NULL to strcmp here as the function _parse_param_get May return NULL.
@fix
Signed-off-by: Chris Michael <cp.michael@samsung.com>
Diffstat (limited to 'src/bin/edje')
-rw-r--r-- | src/bin/edje/edje_cc_parse.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/bin/edje/edje_cc_parse.c b/src/bin/edje/edje_cc_parse.c index 9c4e6bcc08..5f405dfc7f 100644 --- a/src/bin/edje/edje_cc_parse.c +++ b/src/bin/edje/edje_cc_parse.c | |||
@@ -1843,10 +1843,14 @@ int | |||
1843 | get_param_index(char *str) | 1843 | get_param_index(char *str) |
1844 | { | 1844 | { |
1845 | int index; | 1845 | int index; |
1846 | char *p; | ||
1846 | 1847 | ||
1847 | for(index = 0; index < get_arg_count(); index++) | 1848 | for(index = 0; index < get_arg_count(); index++) |
1848 | { | 1849 | { |
1849 | if(!strcmp(str,_parse_param_get(index))) | 1850 | p = _parse_param_get(index); |
1851 | if (!p) continue; | ||
1852 | |||
1853 | if (!strcmp(str, p)) | ||
1850 | return index; | 1854 | return index; |
1851 | } | 1855 | } |
1852 | 1856 | ||