Skip to content

Commit 8d75ca1

Browse files
pedberg-icuDraganBesevic
authored andcommitted
ICU-23056 Integrate CLDR 48 release alpha0, part 5, fix some memory leaks due to logKnownIssue test skips
1 parent e50bac8 commit 8d75ca1

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

icu4c/source/test/intltest/dtifmtts.cpp

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1246,7 +1246,7 @@ void DateIntervalFormatTest::expect(const char** data, int32_t data_length) {
12461246

12471247
const UnicodeString& oneSkeleton(ctou(data[i++]));
12481248

1249-
DateIntervalFormat* dtitvfmt = DateIntervalFormat::createInstance(oneSkeleton, loc, ec);
1249+
LocalPointer<DateIntervalFormat> dtitvfmt(DateIntervalFormat::createInstance(oneSkeleton, loc, ec));
12501250
if (!assertSuccess("createInstance(skeleton) in expect", ec)) return;
12511251
FieldPosition pos(FieldPosition::DONT_CARE);
12521252
dtitvfmt->format(&dtitv, str.remove(), pos, ec);
@@ -1270,7 +1270,6 @@ void DateIntervalFormatTest::expect(const char** data, int32_t data_length) {
12701270
logln("interval date:" + str + "\"" + locName + "\", "
12711271
+ "\"" + datestr + "\", "
12721272
+ "\"" + datestr_2 + "\", " + oneSkeleton);
1273-
delete dtitvfmt;
12741273
}
12751274
}
12761275

icu4c/source/test/intltest/numfmtst.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -977,7 +977,8 @@ NumberFormatTest::TestCurrency()
977977
}
978978
if (strcmp(localeID, "gl_ES@currency=ESP") == 0 &&
979979
logKnownIssue("CLDR-18901", "Problem with ❰NBTSP❱")) {
980-
continue;
980+
delete currencyFmt;
981+
continue;
981982
}
982983
currencyFmt->format(1150.50, s);
983984
if(s!=expected){

0 commit comments

Comments
 (0)