From 0bbbe4b84f18661d1ab442472b5fd70d6e1a3c49 Mon Sep 17 00:00:00 2001 From: Ram Viswanadha Date: Sat, 17 Mar 2007 01:22:52 +0000 Subject: [PATCH] ICU-5273 fix IDNAToUnicode to not fail on error X-SVN-Rev: 21277 --- icu4c/source/common/uidna.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/icu4c/source/common/uidna.cpp b/icu4c/source/common/uidna.cpp index ed678d6458..ad42b45412 100644 --- a/icu4c/source/common/uidna.cpp +++ b/icu4c/source/common/uidna.cpp @@ -477,7 +477,7 @@ _internal_toUnicode(const UChar* src, int32_t srcLength, } //step 3: verify ACE Prefix - if(startsWithPrefix(src,srcLength)){ + if(startsWithPrefix(b1,b1Len)){ //step 4: Remove the ACE Prefix b1Prime = b1 + ACE_PREFIX_LENGTH; @@ -591,6 +591,7 @@ CLEANUP: } } reqLength = srcLength; + *status = U_ZERO_ERROR; } return u_terminateUChars(dest, destCapacity, reqLength, status);