allocating 0 bytes: stay classy e

SVN revision: 64883
This commit is contained in:
Mike Blumenkrantz 2011-11-07 22:29:29 +00:00
parent c3fff8a8a7
commit 9a1b59641a
1 changed files with 2 additions and 0 deletions

View File

@ -784,6 +784,8 @@ e_intl_locale_parts_combine(E_Locale_Parts *locale_parts, int mask)
if (mask & E_INTL_LOC_MODIFIER)
locale_size += strlen(locale_parts->modifier) + 1;
if (!locale_size) return NULL;
/* Allocate memory */
locale = (char *) malloc(locale_size);
locale[0] = 0;