ICU-5188 allow empty substitution string

X-SVN-Rev: 19791
This commit is contained in:
Markus Scherer 2006-07-06 06:19:23 +00:00
parent 93bef44b15
commit 6264fe3f47

View file

@ -271,7 +271,7 @@ ConversionTest::TestFromUnicode() {
// read a substitution string, separated by an equal sign
p=s.getBuffer()+index+1;
length=s.length()-(index+1);
if(length<=0 || length>=LENGTHOF(cc.subString)) {
if(length<0 || length>=LENGTHOF(cc.subString)) {
errorCode=U_ILLEGAL_ARGUMENT_ERROR;
} else {
u_memcpy(cc.subString, p, length);