[SE][Ref.App][Tizen_3.0_Beta_RC16][Mobile][Email][UIT] Email is force close after... 50/79250/1 submit/tizen/20160710.064732
authorIgor Olshevskyi <i.olshevskyi@samsung.com>
Sat, 9 Jul 2016 09:57:15 +0000 (12:57 +0300)
committerIgor Olshevskyi <i.olshevskyi@samsung.com>
Sat, 9 Jul 2016 11:41:14 +0000 (14:41 +0300)
Change-Id: Idd59e9084b19456f1f9aaa6855bd65ea0ecc55a9

common/src/email-utils.c

index 9fb10db..db34786 100644 (file)
@@ -2229,7 +2229,9 @@ EMAIL_API char *email_get_datetime_format(void)
        int res = 0;
        bool is_hour24 = false;
 
-       lang = getenv("LANGUAGE");
+       lang = strdup(getenv("LANGUAGE"));
+       retvm_if(lang == NULL, NULL, "lang is NULL. Allocation memory failed.");
+
        _update_lang_environment("en_US");
 
        res = system_settings_get_value_string(SYSTEM_SETTINGS_KEY_LOCALE_COUNTRY, &region_fmt);