[BinType] PDA [Customer] Public/Open/ ... [Issue#] N/A [Problem]
language value have character set [Cause] vconf language value have
character set [Solution] remove chracter set [Team] Kernel&SystemFW
[Developer] kw46.nam [Request] N/A [Horizontal expansion] N/A
[SCMRequest] N/A
Change-Id: I572406f4475413d475fe4bca9038c8454b3ac9d2
int runtime_info_language_get_value(runtime_info_value_h value)
{
char *vconf_value;
-
+ char *token = NULL;
+
if (runtime_info_vconf_get_value_string(VCONF_LANGUAGE, &vconf_value))
{
return RUNTIME_INFO_ERROR_IO_ERROR;
}
- value->s = vconf_value;
+ token = strtok(vconf_value, ".");
+ value->s = strdup(token);
+ free(vconf_value);
+ if (value->s == NULL) {
+ LOGE("[%s] OUT_OF_MEMORY(0x%08x)", __func__, RUNTIME_INFO_ERROR_OUT_OF_MEMORY);
+ return RUNTIME_INFO_ERROR_OUT_OF_MEMORY;
+ }
return RUNTIME_INFO_ERROR_NONE;
}