From 6d5ecbfc0885d26edd721a86c17dcc019da4f037 Mon Sep 17 00:00:00 2001 From: George Rhoten Date: Sat, 23 Mar 2002 00:25:51 +0000 Subject: [PATCH] ICU-1733 Forgot a change from Lotus. X-SVN-Rev: 8216 --- icu4c/source/i18n/msgfmt.cpp | 4 ++-- icu4c/source/test/intltest/tchcfmt.cpp | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/icu4c/source/i18n/msgfmt.cpp b/icu4c/source/i18n/msgfmt.cpp index 0c971074b6..6ba6e128cb 100644 --- a/icu4c/source/i18n/msgfmt.cpp +++ b/icu4c/source/i18n/msgfmt.cpp @@ -183,9 +183,9 @@ MessageFormat::MessageFormat(const MessageFormat& that) : Format(that), fLocale(that.fLocale), fPattern(that.fPattern), - fOffsets(new int32_t[that.fCount]), + fOffsets((int32_t *)uprv_malloc(that.fCount * sizeof(int32_t))), fCount(that.fCount), - fArgumentNumbers(new int32_t[that.fCount]), + fArgumentNumbers((int32_t *)uprv_malloc(that.fCount * sizeof(int32_t))), fMaxOffset(that.fMaxOffset) { // Sets up the format instance array, offsets and argument numbers. diff --git a/icu4c/source/test/intltest/tchcfmt.cpp b/icu4c/source/test/intltest/tchcfmt.cpp index bbca01abae..b5d490a487 100644 --- a/icu4c/source/test/intltest/tchcfmt.cpp +++ b/icu4c/source/test/intltest/tchcfmt.cpp @@ -84,7 +84,7 @@ TestChoiceFormat::TestSimpleExample( void ) delete formequal; //Testing adoptChoices() - double *limitsToAdopt = new double[7]; + double *limitsToAdopt = (double *)uprv_malloc(7 * sizeof(double)); UnicodeString *monthNamesToAdopt = new UnicodeString[7]; uprv_arrayCopy(monthNames, monthNamesToAdopt, 7); @@ -376,7 +376,7 @@ TestChoiceFormat::TestComplexExample( void ) it_errln("*** ChoiceFormat contructor( newPattern, status) or toPattern result!"); } - double* d_a = new double[2]; + double* d_a = (double *)uprv_malloc(2 * sizeof(double)); if (!d_a) { it_errln("*** allocation error."); return; } d_a[0] = 1.0; d_a[1] = 2.0;