]> git.saurik.com Git - apple/icu.git/blobdiff - icuSources/test/cintltst/spooftest.c
ICU-531.30.tar.gz
[apple/icu.git] / icuSources / test / cintltst / spooftest.c
index 7096ad263a922fb5f3dafdadd7ea7a57bd5d8551..d90f8878204a1aedf422ccb90a3de61e740595f4 100644 (file)
@@ -132,9 +132,9 @@ static void TestUSpoofCAPI(void) {
     const char *dataSrcDir;
     char       *fileName;
     char       *confusables;
-    int         confusablesLength;
+    int         confusablesLength = 0;
     char       *confusablesWholeScript;
-    int         confusablesWholeScriptLength;
+    int         confusablesWholeScriptLength = 0;
     FILE       *f;
     UParseError pe;
     int32_t     errType;
@@ -148,8 +148,8 @@ static void TestUSpoofCAPI(void) {
     TEST_ASSERT_NE(f, NULL);
     confusables = malloc(3000000);
     if (f != NULL) {
-    confusablesLength = fread(confusables, 1, 3000000, f);
-    fclose(f);
+        confusablesLength = fread(confusables, 1, 3000000, f);
+        fclose(f);
     }
 
     strcpy(fileName, dataSrcDir);
@@ -158,8 +158,8 @@ static void TestUSpoofCAPI(void) {
     TEST_ASSERT_NE(f, NULL);
     confusablesWholeScript = malloc(1000000);
     if (f != NULL) {
-    confusablesWholeScriptLength = fread(confusablesWholeScript, 1, 1000000, f);
-    fclose(f);
+        confusablesWholeScriptLength = fread(confusablesWholeScript, 1, 1000000, f);
+        fclose(f);
     }
 
     rsc = uspoof_openFromSource(confusables, confusablesLength,