free result on error.

set group to NULL, since it references data.


SVN revision: 26062
This commit is contained in:
sebastid 2006-09-23 11:12:39 +00:00 committed by sebastid
parent 609839c524
commit 6ce6b42f71
1 changed files with 2 additions and 0 deletions

View File

@ -522,6 +522,7 @@ ecore_desktop_icon_theme_get(const char *icon_theme, const char *lang)
ecore_hash_set(icon_theme_cache, strdup(icon_theme), result);
ecore_hash_destroy(result->data);
result->data = NULL;
result->group = NULL;
done:
if (dir) free(dir);
@ -536,6 +537,7 @@ error:
{
_ecore_desktop_icon_theme_destroy(result);
if (result->data) ecore_hash_destroy(result->data);
free(result);
}
return NULL;
}