X-Git-Url: https://git.saurik.com/apple/icu.git/blobdiff_plain/374ca955a76ecab1204ca8bfa63ff9238d998416..d5d484b0fbe924d3663b177965538d517ee412c1:/icuSources/tools/ctestfw/datamap.cpp diff --git a/icuSources/tools/ctestfw/datamap.cpp b/icuSources/tools/ctestfw/datamap.cpp index 30da4500..e9242dec 100644 --- a/icuSources/tools/ctestfw/datamap.cpp +++ b/icuSources/tools/ctestfw/datamap.cpp @@ -1,6 +1,6 @@ /******************************************************************** * COPYRIGHT: - * Copyright (c) 2002-2004, International Business Machines Corporation and + * Copyright (c) 2002-2006, International Business Machines Corporation and * others. All Rights Reserved. ********************************************************************/ @@ -69,7 +69,7 @@ void RBDataMap::init(UResourceBundle *data, UErrorCode &status) { UResourceBundle *t = NULL; for(i = 0; i < ures_getSize(data); i++) { t = ures_getByIndex(data, i, t, &status); - fData->put(UnicodeString(ures_getKey(t), ""), new ResourceBundle(t, status), status); + fData->put(UnicodeString(ures_getKey(t), -1, US_INV), new ResourceBundle(t, status), status); } ures_close(t); } @@ -100,7 +100,7 @@ const ResourceBundle *RBDataMap::getItem(const char* key, UErrorCode &status) co return NULL; } - UnicodeString hashKey(key, ""); + UnicodeString hashKey(key, -1, US_INV); const ResourceBundle *r = (ResourceBundle *)fData->get(hashKey); if(r != NULL) { return r; @@ -116,7 +116,6 @@ const UnicodeString RBDataMap::getString(const char* key, UErrorCode &status) co if(U_SUCCESS(status)) { return r->getString(status); } else { - status = U_MISSING_RESOURCE_ERROR; return UnicodeString(); } } @@ -190,7 +189,6 @@ const UnicodeString* RBDataMap::getStringArray(int32_t& count, const char* key, } return result; } else { - status = U_MISSING_RESOURCE_ERROR; return NULL; } } @@ -214,7 +212,7 @@ const int32_t* RBDataMap::getIntArray(int32_t& count, const char* key, UErrorCod } return result; } else { - status = U_MISSING_RESOURCE_ERROR; return NULL; } } +