Resolve the "Klocwork" detected defect and add debug feature.
[platform/framework/native/appfw.git] / src / locales / FLclLocale.cpp
index 5e3af15..03ce769 100644 (file)
@@ -1045,9 +1045,9 @@ Locale::TwoLetterLanguageCodeStringToLanguageCode(const String& languageCodeStri
 {
        int index = -1;
 
-       result r = languageCodeString.IndexOf(L"-", 0, index);
+       languageCodeString.IndexOf(L"-", 0, index);
 
-       if ((r == E_SUCCESS) && (languageCodeString.GetLength() == 2 || index == 2))
+       if (languageCodeString.GetLength() == 2 || index == 2)
        {
                std::unique_ptr<char[]> pLangStr (_StringConverter::CopyToCharArrayN(languageCodeString));
                return StringToLanguageCode(_LocaleImpl::Get3LetterLanguageCodeString(pLangStr.get()));