[Verifivation] code compiles without error.
Change-Id: I85ae0d095107750ff75bd39efb594f8af94e1b9c
Signed-off-by: Lukasz Bardeli <l.bardeli@samsung.com>
Locale CordovaGlobalizationTools::GetDefaultLocale() {
LoggerD("Entered");
char* tempstr = vconf_get_str(VCONFKEY_REGIONFORMAT);
+ std::unique_ptr<char*> tempstr_ptr(&tempstr);
if (nullptr != tempstr){
LoggerD("Region: %s", tempstr);
if (len > 0) {
char* str_region = strndup(tempstr, len); //.UTF8 => 5
- free(tempstr);
Locale result = Locale::createFromName(str_region);
free(str_region);
return result;