If strdup failed, don't try and free the wrong thing.

This commit is contained in:
peter 2013-07-01 08:38:31 +00:00
parent c77016ccda
commit 4a24ccbeb9

View File

@ -96,7 +96,7 @@ _citrus_mapper_create_area(
ma->ma_dir = strdup(area);
if (ma->ma_dir == NULL) {
ret = errno;
free(ma->ma_dir);
free(ma);
goto quit;
}
_CITRUS_HASH_INIT(&ma->ma_cache, CM_HASH_SIZE);