]> git.saurik.com Git - apple/icu.git/blobdiff - icuSources/test/intltest/testidn.cpp
ICU-400.37.tar.gz
[apple/icu.git] / icuSources / test / intltest / testidn.cpp
index 8cc9b1687faaabdee86fc4063d6af36207fa9d67..e1f627735db25c63155cf51d96d5a0c13fecab89 100644 (file)
@@ -77,9 +77,6 @@ static const uint16_t *mappingData       = NULL;
 
 extern int
 testData(TestIDNA& test) {
-    char* filename = (char*) malloc(strlen(IntlTest::pathToDataDirectory())*5555);
-    //TODO get the srcDir dynamically 
-    const char *srcDir=IntlTest::pathToDataDirectory();
     char *basename=NULL;
     UErrorCode errorCode=U_ZERO_ERROR;
     char *saveBasename =NULL;
@@ -90,6 +87,10 @@ testData(TestIDNA& test) {
         return errorCode;
     }
     
+    char* filename = (char*) malloc(strlen(IntlTest::pathToDataDirectory())*1024);
+    //TODO get the srcDir dynamically 
+    const char *srcDir=IntlTest::pathToDataDirectory();
+
     idnTrie     = &profile->sprepTrie;
     indexes     = profile->indexes;
     mappingData = profile->mappingData;