forked from enlightenment/efl
Fix memleak reported by Coverity: If we error out because we have a
hash with no key, then free the previously allocated data_stream. NB: Fixes Coverity CID1039262 Signed-off-by: Chris Michael <cp.michael@samsung.com>
This commit is contained in:
parent
b72e694573
commit
e28f298dbd
|
@ -2891,8 +2891,15 @@ _eet_data_dump_encode(int parent_type,
|
|||
node->type);
|
||||
}
|
||||
else
|
||||
/* A Hash without key will not decode correctly. */
|
||||
return NULL;
|
||||
{
|
||||
/* A Hash without key will not decode correctly. */
|
||||
|
||||
ds->data = NULL;
|
||||
ds->size = 0;
|
||||
eet_data_stream_free(ds);
|
||||
|
||||
return NULL;
|
||||
}
|
||||
|
||||
for (n = node->values; n; n = n->next)
|
||||
{
|
||||
|
|
Loading…
Reference in New Issue