projects
/
platform
/
upstream
/
efl.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
de13560
)
Malloc cannot accept a negative number so check 'num' parameter before
author
Chris Michael
<cp.michael@samsung.com>
Mon, 18 Nov 2013 11:48:00 +0000
(11:48 +0000)
committer
Chris Michael
<cp.michael@samsung.com>
Mon, 18 Nov 2013 11:50:42 +0000
(11:50 +0000)
calling malloc.
Fixes Coverity CID1039352
Signed-off-by: Chris Michael <cp.michael@samsung.com>
src/lib/ecore_con/ecore_con.c
patch
|
blob
|
history
diff --git
a/src/lib/ecore_con/ecore_con.c
b/src/lib/ecore_con/ecore_con.c
index
fece5f3
..
d28a845
100644
(file)
--- a/
src/lib/ecore_con/ecore_con.c
+++ b/
src/lib/ecore_con/ecore_con.c
@@
-1176,7
+1176,7
@@
ecore_con_event_client_data(Ecore_Con_Client *cl, unsigned char *buf, int num, E
cl->host_server->event_count = eina_list_append(cl->host_server->event_count, e);
_ecore_con_cl_timer_update(cl);
e->client = cl;
- if (
duplicate
)
+ if (
(duplicate) && (num > 0)
)
{
e->data = malloc(num);
if (!e->data)