mirror of
https://gitee.com/openharmony/third_party_icu
synced 2024-11-27 02:11:01 +00:00
漏洞修改4
Signed-off-by: zhangdd_ewan <zhangdongdong50@huawei.com>
This commit is contained in:
parent
9226c7941f
commit
171d850f3e
@ -31,6 +31,7 @@
|
||||
#include "charstr.h"
|
||||
#include "cmemory.h"
|
||||
#include "cstring.h"
|
||||
#include "loclikelysubtags.h"
|
||||
#include "ulocimp.h"
|
||||
#include "ustr_imp.h"
|
||||
|
||||
@ -1070,7 +1071,7 @@ uloc_minimizeSubtags(const char* localeID,
|
||||
icu::CheckedArrayByteSink sink(
|
||||
minimizedLocaleID, minimizedLocaleIDCapacity);
|
||||
|
||||
ulocimp_minimizeSubtags(localeID, sink, status);
|
||||
ulocimp_minimizeSubtags(localeID, sink, false, status);
|
||||
int32_t reslen = sink.NumberOfBytesAppended();
|
||||
|
||||
if (U_FAILURE(*status)) {
|
||||
|
@ -11,6 +11,7 @@
|
||||
#include "unicode/utypes.h"
|
||||
#include "unicode/bytestrie.h"
|
||||
#include "unicode/locid.h"
|
||||
#include "unicode/stringpiece.h"
|
||||
#include "unicode/uobject.h"
|
||||
#include "unicode/ures.h"
|
||||
#include "charstrmap.h"
|
||||
@ -61,13 +62,9 @@ public:
|
||||
*/
|
||||
int32_t compareLikely(const LSR &lsr, const LSR &other, int32_t likelyInfo) const;
|
||||
|
||||
// TODO(ICU-20777): Switch Locale/uloc_ likely-subtags API from the old code
|
||||
// in loclikely.cpp to this new code, including activating this
|
||||
// minimizeSubtags() function. The LocaleMatcher does not minimize.
|
||||
#if 0
|
||||
LSR minimizeSubtags(const char *languageIn, const char *scriptIn, const char *regionIn,
|
||||
ULocale.Minimize fieldToFavor, UErrorCode &errorCode) const;
|
||||
#endif
|
||||
LSR minimizeSubtags(StringPiece language, StringPiece script, StringPiece region,
|
||||
bool favorScript,
|
||||
UErrorCode &errorCode) const;
|
||||
|
||||
// visible for LocaleDistance
|
||||
const LocaleDistanceData &getDistanceData() const { return distanceData; }
|
||||
|
Loading…
Reference in New Issue
Block a user