]> git.saurik.com Git - apple/icu.git/blobdiff - icuSources/common/uresbund.cpp
ICU-62107.0.1.tar.gz
[apple/icu.git] / icuSources / common / uresbund.cpp
index c010421808cc782ccbd08b9e0e99698dc1503ade..26a23e7089f655b7acf9833fda6b36f96176a14f 100644 (file)
@@ -1083,6 +1083,7 @@ static UResourceBundle *init_resb_result(const ResourceData *rdata, Resource r,
                                 pathBuf = (char *)uprv_malloc((uprv_strlen(keyPath)+1)*sizeof(char));
                                 if(pathBuf == NULL) {
                                     *status = U_MEMORY_ALLOCATION_ERROR;
+                                    ures_close(mainRes);
                                     return NULL;
                                 }
                             }