Revert "Delete checking if strlen() is 0 in ConvertWcsToMbsN()"
authorDahyeong Kim <dahyeong.kim@tizendev.org>
Thu, 18 Apr 2013 10:45:28 +0000 (19:45 +0900)
committerGerrit Code Review <gerrit2@kim11>
Thu, 18 Apr 2013 10:45:28 +0000 (19:45 +0900)
This reverts commit e5e892720fb5d6518bcdbb674113b32f55d2720b

src/base/utility/FBaseUtil_IcuConverter.cpp

index ae410f8..38c4aa7 100644 (file)
@@ -208,6 +208,7 @@ ConvertWcsToMbsN(const wchar_t* pValue)
        SysTryReturn(NID_BASE_UTIL, pValue != null, null, E_INVALID_ARG, "[%s] Invalid argument is used. The pValue is null.", GetErrorMessage(E_INVALID_ARG));
 
        int len = wcslen(pValue);
+       SysTryReturn(NID_BASE_UTIL, len != 0, null, E_INVALID_ARG, "[%s] Invalid argument is used. The pValue is an empty string.", GetErrorMessage(E_INVALID_ARG));
 
        UErrorCode err = U_ZERO_ERROR;
        UConverter* pConverter = ucnv_open("UTF-8", &err);