ICU-1913 Make sure that the U_COL_SAFECLONE_BUFFERSIZE has the right size on os/400 with a better error message

X-SVN-Rev: 8676
This commit is contained in:
George Rhoten 2002-05-23 00:11:42 +00:00
parent 525588c474
commit 256ed9a3d3

View File

@ -542,7 +542,12 @@ void TestSafeClone() {
uint8_t buffer [CLONETEST_COLLATOR_COUNT] [U_COL_SAFECLONE_BUFFERSIZE];
int32_t bufferSize = U_COL_SAFECLONE_BUFFERSIZE;
int index;
if (U_COL_SAFECLONE_BUFFERSIZE < sizeof(UCollator)) {
log_err("U_COL_SAFECLONE_BUFFERSIZE should be larger than sizeof(UCollator)\n");
return;
}
test1=(UChar*)malloc(sizeof(UChar) * testSize);
test2=(UChar*)malloc(sizeof(UChar) * testSize);
u_uastrcpy(test1, "abCda");