Repository navigation
ICU-20036 CurrencyPluralInfo class improve handling of OOM errors - #17
Conversation
…ets fPluralRules and fLocale to nullptr in the assignment operator in order to prevent possible double deletes in the failure case. Also use LocalPointer in a few more cases in order to clean things up somewhat.
| } | ||
| delete fLocale; | ||
| fLocale = loc.clone(); | ||
| if (fLocale) { |
There was a problem hiding this comment.
In some methods, like operator=, you delete without checking first, but here you first check if the pointer is not nullptr before calling delete. Personally I like the first style better, but at a minimum you should probably be consistent in your style. #Resolved
There was a problem hiding this comment.
Thanks Shane. I was trying to mimic the style within each function (if it checked for nullptr, then I would too. If it didn't then I didn't).
However, since I'm already making a bunch of changes it would probably be better to be consistent.
Since calling delete on nullptr is safe, it seems like it would be cleaner to omit the checks.
In reply to: 207376490 [](ancestors = 207376490)
| UErrorCode ec = U_ZERO_ERROR; | ||
| UResourceBundle *rb = ures_open(NULL, loc.getName(), &ec); | ||
| UResourceBundle *numElements = ures_getByKeyWithFallback(rb, gNumberElementsTag, NULL, &ec); | ||
| UResourceBundle *rb = ures_open(nullptr, loc.getName(), &ec); |
There was a problem hiding this comment.
Suggestion: change this to LocalUResourceBundlePointer. #Resolved
There was a problem hiding this comment.
…ing for nullptr when calling delete.
…order to simply the code and not need manual deletes.
sffc
left a comment
There was a problem hiding this comment.
LGTM, with some additional optional suggestions.
| rb = ures_getByKeyWithFallback(rb, gPatternsTag, rb, &ec); | ||
| LocalUResourceBundlePointer rb(ures_open(nullptr, loc.getName(), &ec)); | ||
| LocalUResourceBundlePointer numElements(ures_getByKeyWithFallback(rb.getAlias(), gNumberElementsTag, nullptr, &ec)); | ||
| LocalUResourceBundlePointer numSystemScript(ures_getByKeyWithFallback(numElements.getAlias(), ns->getName(), nullptr, &ec)); |
There was a problem hiding this comment.
It's fine, but I think it should still be safe to use the third argument of ures_getByKeyWithFallback rather than making a new LocalUResourceBundlePointer for every level in the resource bundle tree.
There was a problem hiding this comment.
I thought about that too, but then I was wondering who would call close on the ResourceBundle? (and in the correct order).
IIUC, calling orphan() doesn't call the close function, and if you call getAlias(), then the original bundle might be overwritten before the adoptInstead() can call close.
Ex:
rb.adoptInstead(ures_getByKeyWithFallback(numElements.getAlias(), ns->getName(), rb.orphan(), &ec));
rb.adoptInstead(ures_getByKeyWithFallback(numElements.getAlias(), ns->getName(), rb.getAlias(), &ec));
In reply to: 207658933 [](ancestors = 207658933)
There was a problem hiding this comment.
What I meant was, I think it is safe to do,
LocalUResourceBundlePointer rb(ures_open(...));
ures_getByKeyWithFallback(rb.getAlias(), "...", rb.getAlias(), &ec);
ures_getByKeyWithFallback(rb.getAlias(), "...", rb.getAlias(), &ec);
ures_getByKeyWithFallback(rb.getAlias(), "...", rb.getAlias(), &ec);
Example of a place in ICU code that uses this pattern already:
icu/icu4c/source/i18n/reldtfmt.cpp
Line 450 in 778d0a6
I'm double-checking with Markus that this is safe.
There was a problem hiding this comment.
After studying uresbund.cpp, I can't find any code paths in ures_getByKeyWithFallback and related functions that obviously return a different object than the one you passed via the fillIn parameter. Markus didn't have an answer. The documentation also does not provide any clues.
There is one thing that we can assume, and it's that when you pass a fillIn parameter to ures_getByKeyWithFallback, that you are passing ownership to that function, because most call sites, including the one you are refactoring, overwrite the original rb pointer with the return value. In most cases, ures_getByKeyWithFallback hands ownership of fillIn right back again by returning the same pointer; the question which I can't give a 100% certain answer to is whether fillIn is always the return value when it is non-null.
What I can see by looking at the code is that you should be able to expect better performance by using the fillIn, because without the fillIn, you add extra mallocs.
I think the pattern I posted above is probably fine, since I can find other places in ICU code that use it, but if you are hesitant, then I think the following pattern is also definitely safe:
LocalUResourceBundlePointer rb(ures_open(...));
rb.adoptInstead(ures_getByKeyWithFallback(rb.getAlias(), "...", rb.orphan(), &ec));
rb.adoptInstead(ures_getByKeyWithFallback(rb.getAlias(), "...", rb.orphan(), &ec));
rb.adoptInstead(ures_getByKeyWithFallback(rb.getAlias(), "...", rb.orphan(), &ec));
rb.getAlias() gets called first, then rb.orphan(), then ures_getByKeyWithFallback does its stuff, then you save the result back into rb.
There was a problem hiding this comment.
Thanks Shane.
My hesitation about using that exact pattern was more about the question of "who calls the ures_close" once the code is done with the Resource Bundle, in order to ensure that there are no leaks. I was thinking that when you pass the fillIn it might not close.
However, from taking a close look at the code, it looks like it will automatically call the appropriate close methods if the fillIn argument is not NULL.
Inside the init_resb_result function:
if(resB == NULL) {
// .... omitted...
} else {
if(resB->fData != NULL) {
entryClose(resB->fData);
}
if(resB->fVersion != NULL) {
uprv_free(resB->fVersion);
}
// .... omitted...
}So, yes I would agree that it is safe in terms of not leaking when you use this pattern.
In terms of the pattern below, I think that even if getByKeyWithFallback did allocate a new object, it would still modify the incoming argument/parameter fillIn.
Pattern:
LocalUResourceBundlePointer rb(ures_open(...));
ures_getByKeyWithFallback(rb.getAlias(), "...", rb.getAlias(), &ec);ICU Code:
U_CAPI UResourceBundle* U_EXPORT2
ures_getByKeyWithFallback(const UResourceBundle *resB,
const char* inKey,
UResourceBundle *fillIn,
UErrorCode *status) {
// .....
fillIn = init_resb_result(&(dataEntry->fData), res, inKey, -1, dataEntry, resB, 0, fillIn, status);
} else {
*status = U_MISSING_RESOURCE_ERROR;
}
} else {
fillIn = init_resb_result(&(resB->fResData), res, key, -1, resB->fData, resB, 0, fillIn, status);
}So the rb object might be pointing at a new object after the call if this occurred. But that still would be safe as the close would be called when the LocalUResourceBundlePointer object goes out of scope.
| fPluralRules = nullptr; | ||
| } | ||
| delete fPluralRules; | ||
| fPluralRules = nullptr; |
There was a problem hiding this comment.
Optional: this assignment fPluralRules = nullptr; is redundant with the following line that just reassigns it. Feel free to leave as-is if you think it increases readability. #Resolved
There was a problem hiding this comment.
Thanks Shane. I will push another commit that address this, but I think I will leave the other LocalUResourceBundlePointers for now. #Resolved
…nt due to the reassignment below.
|
LGTM; there are a lot of commits here so I suggest a squash-merge, but you can do a merge commit if you want to preserve the history. |
|
Thank you for the detailed review Shane! |
ICU-20036 CurrencyPluralInfo class doesn't always check/handle OOM errors. Changes include: - Using LocalPointer instead of raw new/delete, in order to make the code cleaner. - Using nullptr instead of NULL. - Inspired by Andy's review feedback PluralRules changes, this change sets fPluralRules and fLocale to nullptr in the assignment operator in order to prevent possible double deletes in the failure case. - More consistent about not checking for nullptr when calling delete. - Using LocalUResourceBundlePointer in order to simply the code and not need manual deletes. - Reduce memory usage by using the same LocalUResourceBundle with .getAlias() instead of allocating new ones.
ICU-20036 CurrencyPluralInfo class doesn't always check/handle OOM errors. Changes include: - Using LocalPointer instead of raw new/delete, in order to make the code cleaner. - Using nullptr instead of NULL. - Inspired by Andy's review feedback PluralRules changes, this change sets fPluralRules and fLocale to nullptr in the assignment operator in order to prevent possible double deletes in the failure case. - More consistent about not checking for nullptr when calling delete. - Using LocalUResourceBundlePointer in order to simply the code and not need manual deletes. - Reduce memory usage by using the same LocalUResourceBundle with .getAlias() instead of allocating new ones.
ICU-20036 CurrencyPluralInfo class doesn't always check/handle OOM errors. Changes include: - Using LocalPointer instead of raw new/delete, in order to make the code cleaner. - Using nullptr instead of NULL. - Inspired by Andy's review feedback PluralRules changes, this change sets fPluralRules and fLocale to nullptr in the assignment operator in order to prevent possible double deletes in the failure case. - More consistent about not checking for nullptr when calling delete. - Using LocalUResourceBundlePointer in order to simply the code and not need manual deletes. - Reduce memory usage by using the same LocalUResourceBundle with .getAlias() instead of allocating new ones.
ICU-20036 CurrencyPluralInfo class doesn't always check/handle OOM errors. Changes include: - Using LocalPointer instead of raw new/delete, in order to make the code cleaner. - Using nullptr instead of NULL. - Inspired by Andy's review feedback PluralRules changes, this change sets fPluralRules and fLocale to nullptr in the assignment operator in order to prevent possible double deletes in the failure case. - More consistent about not checking for nullptr when calling delete. - Using LocalUResourceBundlePointer in order to simply the code and not need manual deletes. - Reduce memory usage by using the same LocalUResourceBundle with .getAlias() instead of allocating new ones.
ICU-20036 CurrencyPluralInfo class doesn't always check/handle OOM errors. Changes include: - Using LocalPointer instead of raw new/delete, in order to make the code cleaner. - Using nullptr instead of NULL. - Inspired by Andy's review feedback PluralRules changes, this change sets fPluralRules and fLocale to nullptr in the assignment operator in order to prevent possible double deletes in the failure case. - More consistent about not checking for nullptr when calling delete. - Using LocalUResourceBundlePointer in order to simply the code and not need manual deletes. - Reduce memory usage by using the same LocalUResourceBundle with .getAlias() instead of allocating new ones.
ICU-20036 CurrencyPluralInfo class doesn't always check/handle OOM errors. Changes include: - Using LocalPointer instead of raw new/delete, in order to make the code cleaner. - Using nullptr instead of NULL. - Inspired by Andy's review feedback PluralRules changes, this change sets fPluralRules and fLocale to nullptr in the assignment operator in order to prevent possible double deletes in the failure case. - More consistent about not checking for nullptr when calling delete. - Using LocalUResourceBundlePointer in order to simply the code and not need manual deletes. - Reduce memory usage by using the same LocalUResourceBundle with .getAlias() instead of allocating new ones.
ICU-20568 Fix ldml2icu convertUnit rules and update units.txt
Load data for compound units
Export addSingleFactorConstant in header file
…unicode-org#17) This change converts the Nuget build pipeline configuration from the ADO "classic" configuration into a YML/YAML file, which can be checked in to the repository. Previously the Nuget build pipeline configuration only existed on MSCodeHub, meaning that nobody else could make any changes to it. This meant that in order to (for example) add support for a new platform to the Nuget package, changes would need to be done manually by someone on our team to the ADO pipeline setup within MSCodeHub. With this change, anyone can create a PR to propose changes to add support for a new platform, etc. to the Nuget package pipeline. This change also fixes the casing on the Nuget name to be "Microsoft.ICU.ICU4C.Runtime". Changes in this commit: * Only add the alpha+buildnum to the Nuget package if prerelease is passed to the script. * Fix the casing on the package name. * Change the wording in the nuspec slightly. * Add YAML build file for Nuget package.
Uninitialized bytes in strlen at offset 0 inside [0x70e002cd131d, 1)
==1637==WARNING: MemorySanitizer: use-of-uninitialized-value
#0 0x55a1c49b5e38 in unsigned long std::__1::__constexpr_strlen[abi:ne210105]<char>(char const*) ci/tmp/build/./contrib/llvm-project/libcxx/include/__string/constexpr_c_functions.h:63:10
#1 0x55a1c49b5e38 in std::__1::char_traits<char>::length[abi:ne210105](char const*) ci/tmp/build/./contrib/llvm-project/libcxx/include/__string/char_traits.h:130:12
#2 0x55a1c49b5e38 in unsigned long std::__1::__char_traits_length_checked[abi:ne210105]<std::__1::char_traits<char>>(std::__1::char_traits<char>::char_type const*) ci/tmp/build/./contrib/llvm-project/libcxx/include/string_view:277:10
#3 0x55a1c49b5e38 in std::__1::basic_string_view<char, std::__1::char_traits<char>>::basic_string_view[abi:ne210105](char const*) ci/tmp/build/./contrib/llvm-project/libcxx/include/string_view:356:31
unicode-org#4 0x55a1c49b5e38 in icu_78::Locale::Nest::Nest(icu_78::Locale::Heap&&, unsigned char) ci/tmp/build/./contrib/icu/icu4c/source/common/locid.cpp:275:32
unicode-org#5 0x55a1c49bf516 in icu_78::Locale::Nest& icu_78::Locale::Payload::emplace<icu_78::Locale::Nest, icu_78::Locale::Heap, unsigned char>(icu_78::Locale::Heap&&, unsigned char&&) ci/tmp/build/./contrib/icu/icu4c/source/common/locid.cpp:434:23
unicode-org#6 0x55a1c49bf516 in icu_78::Locale::setKeywordValue(icu_78::StringPiece, icu_78::StringPiece, UErrorCode&) ci/tmp/build/./contrib/icu/icu4c/source/common/locid.cpp:2799:33
unicode-org#7 0x55a1c4996b63 in icu_78::Locale::setKeywordValue(char const*, char const*, UErrorCode&) ci/tmp/build/./contrib/icu/icu4c/source/common/unicode/locid.h:745:9
unicode-org#8 0x55a1c4998a8b in icu_78::CollationLoader::loadFromData(UErrorCode&) ci/tmp/build/./contrib/icu/icu4c/source/i18n/ucol_res.cpp:452:25
unicode-org#9 0x55a1c4995fcc in icu_78::CollationLoader::createCacheEntry(UErrorCode&) ci/tmp/build/./contrib/icu/icu4c/source/i18n/ucol_res.cpp:233:16
unicode-org#10 0x55a1c4995fcc in icu_78::LocaleCacheKey<icu_78::CollationCacheEntry>::createObject(void const*, UErrorCode&) const ci/tmp/build/./contrib/icu/icu4c/source/i18n/ucol_res.cpp:144:20
unicode-org#11 0x55a1c4b023e3 in icu_78::UnifiedCache::_get(icu_78::CacheKeyBase const&, icu_78::SharedObject const*&, void const*, UErrorCode&) const ci/tmp/build/./contrib/icu/icu4c/source/common/unifiedcache.cpp:394:17
unicode-org#12 0x55a1c49963c7 in void icu_78::UnifiedCache::get<icu_78::CollationCacheEntry>(icu_78::CacheKey<icu_78::CollationCacheEntry> const&, void const*, icu_78::CollationCacheEntry const*&, UErrorCode&) const ci/tmp/build/./contrib/icu/icu4c/source/common/unifiedcache.h:234:8
unicode-org#13 0x55a1c49963c7 in icu_78::CollationLoader::getCacheEntry(UErrorCode&) ci/tmp/build/./contrib/icu/icu4c/source/i18n/ucol_res.cpp:477:12
unicode-org#14 0x55a1c499800b in icu_78::CollationLoader::loadFromCollations(UErrorCode&) ci/tmp/build/./contrib/icu/icu4c/source/i18n/ucol_res.cpp:383:44
unicode-org#15 0x55a1c4995fea in icu_78::CollationLoader::createCacheEntry(UErrorCode&) ci/tmp/build/./contrib/icu/icu4c/source/i18n/ucol_res.cpp:231:16
unicode-org#16 0x55a1c4995fea in icu_78::LocaleCacheKey<icu_78::CollationCacheEntry>::createObject(void const*, UErrorCode&) const ci/tmp/build/./contrib/icu/icu4c/source/i18n/ucol_res.cpp:144:20
unicode-org#17 0x55a1c4b023e3 in icu_78::UnifiedCache::_get(icu_78::CacheKeyBase const&, icu_78::SharedObject const*&, void const*, UErrorCode&) const ci/tmp/build/./contrib/icu/icu4c/source/common/unifiedcache.cpp:394:17
unicode-org#18 0x55a1c49963c7 in void icu_78::UnifiedCache::get<icu_78::CollationCacheEntry>(icu_78::CacheKey<icu_78::CollationCacheEntry> const&, void const*, icu_78::CollationCacheEntry const*&, UErrorCode&) const ci/tmp/build/./contrib/icu/icu4c/source/common/unifiedcache.h:234:8
unicode-org#19 0x55a1c49963c7 in icu_78::CollationLoader::getCacheEntry(UErrorCode&) ci/tmp/build/./contrib/icu/icu4c/source/i18n/ucol_res.cpp:477:12
unicode-org#20 0x55a1c499776a in icu_78::CollationLoader::loadFromBundle(UErrorCode&) ci/tmp/build/./contrib/icu/icu4c/source/i18n/ucol_res.cpp:309:16
unicode-org#21 0x55a1c4997005 in icu_78::CollationLoader::loadFromLocale(UErrorCode&) ci/tmp/build/./contrib/icu/icu4c/source/i18n/ucol_res.cpp:259:16
unicode-org#22 0x55a1c4995fd6 in icu_78::CollationLoader::createCacheEntry(UErrorCode&) ci/tmp/build/./contrib/icu/icu4c/source/i18n/ucol_res.cpp:227:16
unicode-org#23 0x55a1c4995fd6 in icu_78::LocaleCacheKey<icu_78::CollationCacheEntry>::createObject(void const*, UErrorCode&) const ci/tmp/build/./contrib/icu/icu4c/source/i18n/ucol_res.cpp:144:20
unicode-org#24 0x55a1c4b023e3 in icu_78::UnifiedCache::_get(icu_78::CacheKeyBase const&, icu_78::SharedObject const*&, void const*, UErrorCode&) const ci/tmp/build/./contrib/icu/icu4c/source/common/unifiedcache.cpp:394:17
unicode-org#25 0x55a1c49963c7 in void icu_78::UnifiedCache::get<icu_78::CollationCacheEntry>(icu_78::CacheKey<icu_78::CollationCacheEntry> const&, void const*, icu_78::CollationCacheEntry const*&, UErrorCode&) const ci/tmp/build/./contrib/icu/icu4c/source/common/unifiedcache.h:234:8
unicode-org#26 0x55a1c49963c7 in icu_78::CollationLoader::getCacheEntry(UErrorCode&) ci/tmp/build/./contrib/icu/icu4c/source/i18n/ucol_res.cpp:477:12
unicode-org#27 0x55a1c4996164 in icu_78::CollationLoader::loadTailoring(icu_78::Locale const&, UErrorCode&) ci/tmp/build/./contrib/icu/icu4c/source/i18n/ucol_res.cpp:164:19
unicode-org#28 0x55a1c498046c in icu_78::Collator::makeInstance(icu_78::Locale const&, UErrorCode&) ci/tmp/build/./contrib/icu/icu4c/source/i18n/coll.cpp:468:40
unicode-org#29 0x55a1c498046c in icu_78::Collator::createInstance(icu_78::Locale const&, UErrorCode&) ci/tmp/build/./contrib/icu/icu4c/source/i18n/coll.cpp:449:16
unicode-org#30 0x55a1c499945b in ucol_open_78 ci/tmp/build/./contrib/icu/icu4c/source/i18n/ucol_res.cpp:523:22
unicode-org#31 0x55a1ba651b3a in Collator::Collator(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>> const&) ci/tmp/build/./src/Columns/Collator.cpp:109:16
unicode-org#32 0x55a1aba13000 in Collator* std::__1::construct_at[abi:ne210105]<Collator, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>&, Collator*>(Collator*, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>&) ci/tmp/build/./contrib/llvm-project/libcxx/include/__memory/construct_at.h:38:49
unicode-org#33 0x55a1aba13000 in Collator* std::__1::__construct_at[abi:ne210105]<Collator, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>&, Collator*>(Collator*, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>&) ci/tmp/build/./contrib/llvm-project/libcxx/include/__memory/construct_at.h:46:10
unicode-org#34 0x55a1aba13000 in void std::__1::allocator_traits<std::__1::allocator<Collator>>::construct[abi:ne210105]<Collator, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>&, 0>(std::__1::allocator<Collator>&, Collator*, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>&) ci/tmp/build/./contrib/llvm-project/libcxx/include/__memory/allocator_traits.h:302:5
unicode-org#35 0x55a1aba13000 in std::__1::__shared_ptr_emplace<Collator, std::__1::allocator<Collator>>::__shared_ptr_emplace[abi:ne210105]<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>&, std::__1::allocator<Collator>, 0>(std::__1::allocator<Collator>, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>&) ci/tmp/build/./contrib/llvm-project/libcxx/include/__memory/shared_ptr.h:162:5
unicode-org#36 0x55a1aba13000 in std::__1::shared_ptr<Collator> std::__1::allocate_shared[abi:ne210105]<Collator, std::__1::allocator<Collator>, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>&, 0>(std::__1::allocator<Collator> const&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>&) ci/tmp/build/./contrib/llvm-project/libcxx/include/__memory/shared_ptr.h:736:51
unicode-org#37 0x55a1aba13000 in std::__1::shared_ptr<Collator> std::__1::make_shared[abi:ne210105]<Collator, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>&, 0>(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>&) ci/tmp/build/./contrib/llvm-project/libcxx/include/__memory/shared_ptr.h:744:10
unicode-org#38 0x55a1aba13000 in DB::(anonymous namespace)::QueryTreeBuilder::buildSortList(std::__1::shared_ptr<DB::IAST> const&, std::__1::shared_ptr<DB::Context const> const&) const ci/tmp/build/./src/Analyzer/QueryTreeBuilder.cpp:514:24
unicode-org#39 0x55a1aba16771 in DB::(anonymous namespace)::QueryTreeBuilder::buildWindow(std::__1::shared_ptr<DB::IAST> const&, std::__1::shared_ptr<DB::Context const> const&) const ci/tmp/build/./src/Analyzer/QueryTreeBuilder.cpp:818:41
unicode-org#40 0x55a1ab9f06ab in DB::(anonymous namespace)::QueryTreeBuilder::buildExpression(std::__1::shared_ptr<DB::IAST> const&, std::__1::shared_ptr<DB::Context const> const&) const ci/tmp/build/./src/Analyzer/QueryTreeBuilder.cpp:708:58
unicode-org#41 0x55a1ab9eb13b in DB::(anonymous namespace)::QueryTreeBuilder::buildExpressionList(std::__1::shared_ptr<DB::IAST> const&, std::__1::shared_ptr<DB::Context const> const&) const ci/tmp/build/./src/Analyzer/QueryTreeBuilder.cpp:588:32
unicode-org#42 0x55a1aba004f7 in DB::(anonymous namespace)::QueryTreeBuilder::buildSelectExpression(std::__1::shared_ptr<DB::IAST> const&, bool, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>> const&, std::__1::shared_ptr<DB::IAST> const&, std::__1::shared_ptr<DB::Context const> const&) const ci/tmp/build/./src/Analyzer/QueryTreeBuilder.cpp:339:51
unicode-org#43 0x55a1ab9e8ec9 in DB::(anonymous namespace)::QueryTreeBuilder::buildSelectOrUnionExpression(std::__1::shared_ptr<DB::IAST> const&, bool, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>> const&, std::__1::shared_ptr<DB::IAST> const&, std::__1::shared_ptr<DB::Context const> const&) const ci/tmp/build/./src/Analyzer/QueryTreeBuilder.cpp:162:22
unicode-org#44 0x55a1ab9f4620 in DB::(anonymous namespace)::QueryTreeBuilder::buildSelectWithUnionExpression(std::__1::shared_ptr<DB::IAST> const&, bool, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>> const&, std::__1::shared_ptr<DB::IAST> const&, std::__1::shared_ptr<DB::Context const> const&) const ci/tmp/build/./src/Analyzer/QueryTreeBuilder.cpp:180:16
unicode-org#45 0x55a1ab9e8bc1 in DB::(anonymous namespace)::QueryTreeBuilder::buildSelectOrUnionExpression(std::__1::shared_ptr<DB::IAST> const&, bool, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>> const&, std::__1::shared_ptr<DB::IAST> const&, std::__1::shared_ptr<DB::Context const> const&) const ci/tmp/build/./src/Analyzer/QueryTreeBuilder.cpp:158:22
unicode-org#46 0x55a1ab9e5a21 in DB::(anonymous namespace)::QueryTreeBuilder::buildQueryTreeNode(std::__1::shared_ptr<DB::IAST>, std::__1::shared_ptr<DB::Context const>) ci/tmp/build/./src/Analyzer/QueryTreeBuilder.cpp:140:27
unicode-org#47 0x55a1ab9e5a21 in DB::buildQueryTree(std::__1::shared_ptr<DB::IAST>, std::__1::shared_ptr<DB::Context const>) ci/tmp/build/./src/Analyzer/QueryTreeBuilder.cpp:1161:20
unicode-org#48 0x55a1aefdac0d in DB::buildQueryTreeAndRunPasses(std::__1::shared_ptr<DB::IAST> const&, DB::SelectQueryOptions const&, std::__1::shared_ptr<DB::Context const> const&, std::__1::shared_ptr<DB::IStorage> const&) ci/tmp/build/./src/Interpreters/InterpreterSelectQueryAnalyzer.cpp:153:23
unicode-org#49 0x55a1aefd3f6d in DB::InterpreterSelectQueryAnalyzer::InterpreterSelectQueryAnalyzer(std::__1::shared_ptr<DB::IAST> const&, std::__1::shared_ptr<DB::Context const> const&, DB::SelectQueryOptions const&, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>>> const&) ci/tmp/build/./src/Interpreters/InterpreterSelectQueryAnalyzer.cpp:182:18
unicode-org#50 0x55a1aefde9f1 in std::__1::unique_ptr<DB::InterpreterSelectQueryAnalyzer, std::__1::default_delete<DB::InterpreterSelectQueryAnalyzer>> std::__1::make_unique[abi:ne210105]<DB::InterpreterSelectQueryAnalyzer, std::__1::shared_ptr<DB::IAST>&, std::__1::shared_ptr<DB::Context> const&, DB::SelectQueryOptions const&, 0>(std::__1::shared_ptr<DB::IAST>&, std::__1::shared_ptr<DB::Context> const&, DB::SelectQueryOptions const&) ci/tmp/build/./contrib/llvm-project/libcxx/include/__memory/unique_ptr.h:759:30
unicode-org#51 0x55a1aefde4d2 in DB::registerInterpreterSelectQueryAnalyzer(DB::InterpreterFactory&)::$_0::operator()(DB::InterpreterFactory::Arguments const&) const ci/tmp/build/./src/Interpreters/InterpreterSelectQueryAnalyzer.cpp:307:16
unicode-org#52 0x55a1aefde4d2 in decltype(std::declval<DB::registerInterpreterSelectQueryAnalyzer(DB::InterpreterFactory&)::$_0&>()(std::declval<DB::InterpreterFactory::Arguments const&>())) std::__1::__invoke[abi:ne210105]<DB::registerInterpreterSelectQueryAnalyzer(DB::InterpreterFactory&)::$_0&, DB::InterpreterFactory::Arguments const&>(DB::registerInterpreterSelectQueryAnalyzer(DB::InterpreterFactory&)::$_0&, DB::InterpreterFactory::Arguments const&) ci/tmp/build/./contrib/llvm-project/libcxx/include/__type_traits/invoke.h:249:25
unicode-org#53 0x55a1aefde4d2 in std::__1::unique_ptr<DB::IInterpreter, std::__1::default_delete<DB::IInterpreter>> std::__1::__invoke_void_return_wrapper<std::__1::unique_ptr<DB::IInterpreter, std::__1::default_delete<DB::IInterpreter>>, false>::__call[abi:ne210105]<DB::registerInterpreterSelectQueryAnalyzer(DB::InterpreterFactory&)::$_0&, DB::InterpreterFactory::Arguments const&>(DB::registerInterpreterSelectQueryAnalyzer(DB::InterpreterFactory&)::$_0&, DB::InterpreterFactory::Arguments const&) ci/tmp/build/./contrib/llvm-project/libcxx/include/__type_traits/invoke.h:334:12
unicode-org#54 0x55a1aefde4d2 in std::__1::unique_ptr<DB::IInterpreter, std::__1::default_delete<DB::IInterpreter>> std::__1::__invoke_r[abi:ne210105]<std::__1::unique_ptr<DB::IInterpreter, std::__1::default_delete<DB::IInterpreter>>, DB::registerInterpreterSelectQueryAnalyzer(DB::InterpreterFactory&)::$_0&, DB::InterpreterFactory::Arguments const&>(DB::registerInterpreterSelectQueryAnalyzer(DB::InterpreterFactory&)::$_0&, DB::InterpreterFactory::Arguments const&) ci/tmp/build/./contrib/llvm-project/libcxx/include/__type_traits/invoke.h:348:10
unicode-org#55 0x55a1aefde4d2 in std::__1::unique_ptr<DB::IInterpreter, std::__1::default_delete<DB::IInterpreter>> std::__1::__function::__policy_func<std::__1::unique_ptr<DB::IInterpreter, std::__1::default_delete<DB::IInterpreter>> (DB::InterpreterFactory::Arguments const&)>::__call_func[abi:ne210105]<DB::registerInterpreterSelectQueryAnalyzer(DB::InterpreterFactory&)::$_0>(std::__1::__function::__policy_storage const*, DB::InterpreterFactory::Arguments const&) ci/tmp/build/./contrib/llvm-project/libcxx/include/__functional/function.h:450:12
unicode-org#56 0x55a1aee07b17 in std::__1::__function::__policy_func<std::__1::unique_ptr<DB::IInterpreter, std::__1::default_delete<DB::IInterpreter>> (DB::InterpreterFactory::Arguments const&)>::operator()[abi:ne210105](DB::InterpreterFactory::Arguments const&) const ci/tmp/build/./contrib/llvm-project/libcxx/include/__functional/function.h:508:12
unicode-org#57 0x55a1aee07b17 in std::__1::function<std::__1::unique_ptr<DB::IInterpreter, std::__1::default_delete<DB::IInterpreter>> (DB::InterpreterFactory::Arguments const&)>::operator()(DB::InterpreterFactory::Arguments const&) const ci/tmp/build/./contrib/llvm-project/libcxx/include/__functional/function.h:772:10
unicode-org#58 0x55a1aee07b17 in DB::InterpreterFactory::get(std::__1::shared_ptr<DB::IAST>&, std::__1::shared_ptr<DB::Context>, DB::SelectQueryOptions const&) ci/tmp/build/./src/Interpreters/InterpreterFactory.cpp:398:12
unicode-org#59 0x55a1afc33e94 in DB::executeQueryImpl(char const*, char const*, std::__1::shared_ptr<DB::Context>, DB::QueryFlags, DB::QueryProcessingStage::Enum, std::__1::unique_ptr<DB::ReadBuffer, std::__1::default_delete<DB::ReadBuffer>>&, std::__1::shared_ptr<DB::IAST>&, std::__1::shared_ptr<DB::ImplicitTransactionControlExecutor>, std::__1::function<void ()>, DB::QueryResultDetails&) ci/tmp/build/./src/Interpreters/executeQuery.cpp:1545:66
unicode-org#60 0x55a1afc24152 in DB::executeQuery(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>> const&, std::__1::shared_ptr<DB::Context>, DB::QueryFlags, DB::QueryProcessingStage::Enum) ci/tmp/build/./src/Interpreters/executeQuery.cpp:1833:11
unicode-org#61 0x55a1befed98c in DB::TCPHandler::runImpl() ci/tmp/build/./src/Server/TCPHandler.cpp:765:68
unicode-org#62 0x55a1bf06214d in DB::TCPHandler::run() ci/tmp/build/./src/Server/TCPHandler.cpp:2861:9
unicode-org#63 0x55a1cc727d1f in Poco::Net::TCPServerConnection::start() ci/tmp/build/./base/poco/Net/src/TCPServerConnection.cpp:40:3
unicode-org#64 0x55a1cc728d11 in Poco::Net::TCPServerDispatcher::run() ci/tmp/build/./base/poco/Net/src/TCPServerDispatcher.cpp:115:38
unicode-org#65 0x55a1cc5cfbb4 in Poco::PooledThread::run() ci/tmp/build/./base/poco/Foundation/src/ThreadPool.cpp:205:14
unicode-org#66 0x55a1cc5cc06d in Poco::(anonymous namespace)::RunnableHolder::run() ci/tmp/build/./base/poco/Foundation/src/Thread.cpp:45:11
unicode-org#67 0x55a1cc5c8ad0 in Poco::ThreadImpl::runnableEntry(void*) ci/tmp/build/./base/poco/Foundation/src/Thread_POSIX.cpp:341:27
unicode-org#68 0x7f33ed519ac2 (/lib/x86_64-linux-gnu/libc.so.6+0x94ac2) (BuildId: 4f7b0c955c3d81d7cac1501a2498b69d1d82bfe7)
unicode-org#69 0x7f33ed5ab8bf (/lib/x86_64-linux-gnu/libc.so.6+0x1268bf) (BuildId: 4f7b0c955c3d81d7cac1501a2498b69d1d82bfe7)
Member fields were destroyed
#0 0x55a17b0a66fd in __sanitizer_dtor_callback_fields (/home/ubuntu/actions-runner/_work/ClickHouse/ClickHouse/ci/tmp/clickhouse+0xa57c6fd) (BuildId: 90b99d5bc334c7128a6e1b564bd565effb9cdf11)
#1 0x55a1c49b6243 in icu_78::Locale::Heap::~Heap() ci/tmp/build/./contrib/icu/icu4c/source/common/unicode/locid.h:1234:21
#2 0x55a1c49b6243 in icu_78::Locale::Heap::~Heap() ci/tmp/build/./contrib/icu/icu4c/source/common/locid.cpp:346:1
#3 0x55a1c49b68f2 in icu_78::Locale::Payload::~Payload() ci/tmp/build/./contrib/icu/icu4c/source/common/locid.cpp:404:31
unicode-org#4 0x55a1c49bf4fd in icu_78::Locale::Nest& icu_78::Locale::Payload::emplace<icu_78::Locale::Nest, icu_78::Locale::Heap, unsigned char>(icu_78::Locale::Heap&&, unsigned char&&) ci/tmp/build/./contrib/icu/icu4c/source/common/locid.cpp:433:15
unicode-org#5 0x55a1c49bf4fd in icu_78::Locale::setKeywordValue(icu_78::StringPiece, icu_78::StringPiece, UErrorCode&) ci/tmp/build/./contrib/icu/icu4c/source/common/locid.cpp:2799:33
unicode-org#6 0x55a1c4996b63 in icu_78::Locale::setKeywordValue(char const*, char const*, UErrorCode&) ci/tmp/build/./contrib/icu/icu4c/source/common/unicode/locid.h:745:9
unicode-org#7 0x55a1c4998a8b in icu_78::CollationLoader::loadFromData(UErrorCode&) ci/tmp/build/./contrib/icu/icu4c/source/i18n/ucol_res.cpp:452:25
unicode-org#8 0x55a1c4995fcc in icu_78::CollationLoader::createCacheEntry(UErrorCode&) ci/tmp/build/./contrib/icu/icu4c/source/i18n/ucol_res.cpp:233:16
unicode-org#9 0x55a1c4995fcc in icu_78::LocaleCacheKey<icu_78::CollationCacheEntry>::createObject(void const*, UErrorCode&) const ci/tmp/build/./contrib/icu/icu4c/source/i18n/ucol_res.cpp:144:20
unicode-org#10 0x55a1c4b023e3 in icu_78::UnifiedCache::_get(icu_78::CacheKeyBase const&, icu_78::SharedObject const*&, void const*, UErrorCode&) const ci/tmp/build/./contrib/icu/icu4c/source/common/unifiedcache.cpp:394:17
unicode-org#11 0x55a1c49963c7 in void icu_78::UnifiedCache::get<icu_78::CollationCacheEntry>(icu_78::CacheKey<icu_78::CollationCacheEntry> const&, void const*, icu_78::CollationCacheEntry const*&, UErrorCode&) const ci/tmp/build/./contrib/icu/icu4c/source/common/unifiedcache.h:234:8
unicode-org#12 0x55a1c49963c7 in icu_78::CollationLoader::getCacheEntry(UErrorCode&) ci/tmp/build/./contrib/icu/icu4c/source/i18n/ucol_res.cpp:477:12
unicode-org#13 0x55a1c499800b in icu_78::CollationLoader::loadFromCollations(UErrorCode&) ci/tmp/build/./contrib/icu/icu4c/source/i18n/ucol_res.cpp:383:44
unicode-org#14 0x55a1c4995fea in icu_78::CollationLoader::createCacheEntry(UErrorCode&) ci/tmp/build/./contrib/icu/icu4c/source/i18n/ucol_res.cpp:231:16
unicode-org#15 0x55a1c4995fea in icu_78::LocaleCacheKey<icu_78::CollationCacheEntry>::createObject(void const*, UErrorCode&) const ci/tmp/build/./contrib/icu/icu4c/source/i18n/ucol_res.cpp:144:20
unicode-org#16 0x55a1c4b023e3 in icu_78::UnifiedCache::_get(icu_78::CacheKeyBase const&, icu_78::SharedObject const*&, void const*, UErrorCode&) const ci/tmp/build/./contrib/icu/icu4c/source/common/unifiedcache.cpp:394:17
unicode-org#17 0x55a1c49963c7 in void icu_78::UnifiedCache::get<icu_78::CollationCacheEntry>(icu_78::CacheKey<icu_78::CollationCacheEntry> const&, void const*, icu_78::CollationCacheEntry const*&, UErrorCode&) const ci/tmp/build/./contrib/icu/icu4c/source/common/unifiedcache.h:234:8
unicode-org#18 0x55a1c49963c7 in icu_78::CollationLoader::getCacheEntry(UErrorCode&) ci/tmp/build/./contrib/icu/icu4c/source/i18n/ucol_res.cpp:477:12
unicode-org#19 0x55a1c499776a in icu_78::CollationLoader::loadFromBundle(UErrorCode&) ci/tmp/build/./contrib/icu/icu4c/source/i18n/ucol_res.cpp:309:16
unicode-org#20 0x55a1c4997005 in icu_78::CollationLoader::loadFromLocale(UErrorCode&) ci/tmp/build/./contrib/icu/icu4c/source/i18n/ucol_res.cpp:259:16
unicode-org#21 0x55a1c4995fd6 in icu_78::CollationLoader::createCacheEntry(UErrorCode&) ci/tmp/build/./contrib/icu/icu4c/source/i18n/ucol_res.cpp:227:16
unicode-org#22 0x55a1c4995fd6 in icu_78::LocaleCacheKey<icu_78::CollationCacheEntry>::createObject(void const*, UErrorCode&) const ci/tmp/build/./contrib/icu/icu4c/source/i18n/ucol_res.cpp:144:20
unicode-org#23 0x55a1c4b023e3 in icu_78::UnifiedCache::_get(icu_78::CacheKeyBase const&, icu_78::SharedObject const*&, void const*, UErrorCode&) const ci/tmp/build/./contrib/icu/icu4c/source/common/unifiedcache.cpp:394:17
unicode-org#24 0x55a1c49963c7 in void icu_78::UnifiedCache::get<icu_78::CollationCacheEntry>(icu_78::CacheKey<icu_78::CollationCacheEntry> const&, void const*, icu_78::CollationCacheEntry const*&, UErrorCode&) const ci/tmp/build/./contrib/icu/icu4c/source/common/unifiedcache.h:234:8
unicode-org#25 0x55a1c49963c7 in icu_78::CollationLoader::getCacheEntry(UErrorCode&) ci/tmp/build/./contrib/icu/icu4c/source/i18n/ucol_res.cpp:477:12
unicode-org#26 0x55a1c4996164 in icu_78::CollationLoader::loadTailoring(icu_78::Locale const&, UErrorCode&) ci/tmp/build/./contrib/icu/icu4c/source/i18n/ucol_res.cpp:164:19
unicode-org#27 0x55a1c498046c in icu_78::Collator::makeInstance(icu_78::Locale const&, UErrorCode&) ci/tmp/build/./contrib/icu/icu4c/source/i18n/coll.cpp:468:40
unicode-org#28 0x55a1c498046c in icu_78::Collator::createInstance(icu_78::Locale const&, UErrorCode&) ci/tmp/build/./contrib/icu/icu4c/source/i18n/coll.cpp:449:16
SUMMARY: MemorySanitizer: use-of-uninitialized-value ci/tmp/build/./contrib/llvm-project/libcxx/include/__string/constexpr_c_functions.h:63:10 in unsigned long std::__1::__constexpr_strlen[abi:ne210105]<char>(char const*)
Uninitialized bytes in strlen at offset 0 inside [0x70e002cd131d, 1)
==1637==WARNING: MemorySanitizer: use-of-uninitialized-value
#0 0x55a1c49b5e38 in unsigned long std::__1::__constexpr_strlen[abi:ne210105]<char>(char const*) ci/tmp/build/./contrib/llvm-project/libcxx/include/__string/constexpr_c_functions.h:63:10
ClickHouse#1 0x55a1c49b5e38 in std::__1::char_traits<char>::length[abi:ne210105](char const*) ci/tmp/build/./contrib/llvm-project/libcxx/include/__string/char_traits.h:130:12
ClickHouse#2 0x55a1c49b5e38 in unsigned long std::__1::__char_traits_length_checked[abi:ne210105]<std::__1::char_traits<char>>(std::__1::char_traits<char>::char_type const*) ci/tmp/build/./contrib/llvm-project/libcxx/include/string_view:277:10
ClickHouse#3 0x55a1c49b5e38 in std::__1::basic_string_view<char, std::__1::char_traits<char>>::basic_string_view[abi:ne210105](char const*) ci/tmp/build/./contrib/llvm-project/libcxx/include/string_view:356:31
unicode-org#4 0x55a1c49b5e38 in icu_78::Locale::Nest::Nest(icu_78::Locale::Heap&&, unsigned char) ci/tmp/build/./contrib/icu/icu4c/source/common/locid.cpp:275:32
unicode-org#5 0x55a1c49bf516 in icu_78::Locale::Nest& icu_78::Locale::Payload::emplace<icu_78::Locale::Nest, icu_78::Locale::Heap, unsigned char>(icu_78::Locale::Heap&&, unsigned char&&) ci/tmp/build/./contrib/icu/icu4c/source/common/locid.cpp:434:23
unicode-org#6 0x55a1c49bf516 in icu_78::Locale::setKeywordValue(icu_78::StringPiece, icu_78::StringPiece, UErrorCode&) ci/tmp/build/./contrib/icu/icu4c/source/common/locid.cpp:2799:33
unicode-org#7 0x55a1c4996b63 in icu_78::Locale::setKeywordValue(char const*, char const*, UErrorCode&) ci/tmp/build/./contrib/icu/icu4c/source/common/unicode/locid.h:745:9
unicode-org#8 0x55a1c4998a8b in icu_78::CollationLoader::loadFromData(UErrorCode&) ci/tmp/build/./contrib/icu/icu4c/source/i18n/ucol_res.cpp:452:25
unicode-org#9 0x55a1c4995fcc in icu_78::CollationLoader::createCacheEntry(UErrorCode&) ci/tmp/build/./contrib/icu/icu4c/source/i18n/ucol_res.cpp:233:16
unicode-org#10 0x55a1c4995fcc in icu_78::LocaleCacheKey<icu_78::CollationCacheEntry>::createObject(void const*, UErrorCode&) const ci/tmp/build/./contrib/icu/icu4c/source/i18n/ucol_res.cpp:144:20
unicode-org#11 0x55a1c4b023e3 in icu_78::UnifiedCache::_get(icu_78::CacheKeyBase const&, icu_78::SharedObject const*&, void const*, UErrorCode&) const ci/tmp/build/./contrib/icu/icu4c/source/common/unifiedcache.cpp:394:17
unicode-org#12 0x55a1c49963c7 in void icu_78::UnifiedCache::get<icu_78::CollationCacheEntry>(icu_78::CacheKey<icu_78::CollationCacheEntry> const&, void const*, icu_78::CollationCacheEntry const*&, UErrorCode&) const ci/tmp/build/./contrib/icu/icu4c/source/common/unifiedcache.h:234:8
unicode-org#13 0x55a1c49963c7 in icu_78::CollationLoader::getCacheEntry(UErrorCode&) ci/tmp/build/./contrib/icu/icu4c/source/i18n/ucol_res.cpp:477:12
unicode-org#14 0x55a1c499800b in icu_78::CollationLoader::loadFromCollations(UErrorCode&) ci/tmp/build/./contrib/icu/icu4c/source/i18n/ucol_res.cpp:383:44
unicode-org#15 0x55a1c4995fea in icu_78::CollationLoader::createCacheEntry(UErrorCode&) ci/tmp/build/./contrib/icu/icu4c/source/i18n/ucol_res.cpp:231:16
unicode-org#16 0x55a1c4995fea in icu_78::LocaleCacheKey<icu_78::CollationCacheEntry>::createObject(void const*, UErrorCode&) const ci/tmp/build/./contrib/icu/icu4c/source/i18n/ucol_res.cpp:144:20
unicode-org#17 0x55a1c4b023e3 in icu_78::UnifiedCache::_get(icu_78::CacheKeyBase const&, icu_78::SharedObject const*&, void const*, UErrorCode&) const ci/tmp/build/./contrib/icu/icu4c/source/common/unifiedcache.cpp:394:17
unicode-org#18 0x55a1c49963c7 in void icu_78::UnifiedCache::get<icu_78::CollationCacheEntry>(icu_78::CacheKey<icu_78::CollationCacheEntry> const&, void const*, icu_78::CollationCacheEntry const*&, UErrorCode&) const ci/tmp/build/./contrib/icu/icu4c/source/common/unifiedcache.h:234:8
unicode-org#19 0x55a1c49963c7 in icu_78::CollationLoader::getCacheEntry(UErrorCode&) ci/tmp/build/./contrib/icu/icu4c/source/i18n/ucol_res.cpp:477:12
unicode-org#20 0x55a1c499776a in icu_78::CollationLoader::loadFromBundle(UErrorCode&) ci/tmp/build/./contrib/icu/icu4c/source/i18n/ucol_res.cpp:309:16
unicode-org#21 0x55a1c4997005 in icu_78::CollationLoader::loadFromLocale(UErrorCode&) ci/tmp/build/./contrib/icu/icu4c/source/i18n/ucol_res.cpp:259:16
unicode-org#22 0x55a1c4995fd6 in icu_78::CollationLoader::createCacheEntry(UErrorCode&) ci/tmp/build/./contrib/icu/icu4c/source/i18n/ucol_res.cpp:227:16
unicode-org#23 0x55a1c4995fd6 in icu_78::LocaleCacheKey<icu_78::CollationCacheEntry>::createObject(void const*, UErrorCode&) const ci/tmp/build/./contrib/icu/icu4c/source/i18n/ucol_res.cpp:144:20
unicode-org#24 0x55a1c4b023e3 in icu_78::UnifiedCache::_get(icu_78::CacheKeyBase const&, icu_78::SharedObject const*&, void const*, UErrorCode&) const ci/tmp/build/./contrib/icu/icu4c/source/common/unifiedcache.cpp:394:17
unicode-org#25 0x55a1c49963c7 in void icu_78::UnifiedCache::get<icu_78::CollationCacheEntry>(icu_78::CacheKey<icu_78::CollationCacheEntry> const&, void const*, icu_78::CollationCacheEntry const*&, UErrorCode&) const ci/tmp/build/./contrib/icu/icu4c/source/common/unifiedcache.h:234:8
unicode-org#26 0x55a1c49963c7 in icu_78::CollationLoader::getCacheEntry(UErrorCode&) ci/tmp/build/./contrib/icu/icu4c/source/i18n/ucol_res.cpp:477:12
unicode-org#27 0x55a1c4996164 in icu_78::CollationLoader::loadTailoring(icu_78::Locale const&, UErrorCode&) ci/tmp/build/./contrib/icu/icu4c/source/i18n/ucol_res.cpp:164:19
unicode-org#28 0x55a1c498046c in icu_78::Collator::makeInstance(icu_78::Locale const&, UErrorCode&) ci/tmp/build/./contrib/icu/icu4c/source/i18n/coll.cpp:468:40
unicode-org#29 0x55a1c498046c in icu_78::Collator::createInstance(icu_78::Locale const&, UErrorCode&) ci/tmp/build/./contrib/icu/icu4c/source/i18n/coll.cpp:449:16
unicode-org#30 0x55a1c499945b in ucol_open_78 ci/tmp/build/./contrib/icu/icu4c/source/i18n/ucol_res.cpp:523:22
unicode-org#31 0x55a1ba651b3a in Collator::Collator(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>> const&) ci/tmp/build/./src/Columns/Collator.cpp:109:16
unicode-org#32 0x55a1aba13000 in Collator* std::__1::construct_at[abi:ne210105]<Collator, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>&, Collator*>(Collator*, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>&) ci/tmp/build/./contrib/llvm-project/libcxx/include/__memory/construct_at.h:38:49
unicode-org#33 0x55a1aba13000 in Collator* std::__1::__construct_at[abi:ne210105]<Collator, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>&, Collator*>(Collator*, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>&) ci/tmp/build/./contrib/llvm-project/libcxx/include/__memory/construct_at.h:46:10
unicode-org#34 0x55a1aba13000 in void std::__1::allocator_traits<std::__1::allocator<Collator>>::construct[abi:ne210105]<Collator, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>&, 0>(std::__1::allocator<Collator>&, Collator*, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>&) ci/tmp/build/./contrib/llvm-project/libcxx/include/__memory/allocator_traits.h:302:5
unicode-org#35 0x55a1aba13000 in std::__1::__shared_ptr_emplace<Collator, std::__1::allocator<Collator>>::__shared_ptr_emplace[abi:ne210105]<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>&, std::__1::allocator<Collator>, 0>(std::__1::allocator<Collator>, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>&) ci/tmp/build/./contrib/llvm-project/libcxx/include/__memory/shared_ptr.h:162:5
unicode-org#36 0x55a1aba13000 in std::__1::shared_ptr<Collator> std::__1::allocate_shared[abi:ne210105]<Collator, std::__1::allocator<Collator>, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>&, 0>(std::__1::allocator<Collator> const&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>&) ci/tmp/build/./contrib/llvm-project/libcxx/include/__memory/shared_ptr.h:736:51
unicode-org#37 0x55a1aba13000 in std::__1::shared_ptr<Collator> std::__1::make_shared[abi:ne210105]<Collator, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>&, 0>(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>&) ci/tmp/build/./contrib/llvm-project/libcxx/include/__memory/shared_ptr.h:744:10
unicode-org#38 0x55a1aba13000 in DB::(anonymous namespace)::QueryTreeBuilder::buildSortList(std::__1::shared_ptr<DB::IAST> const&, std::__1::shared_ptr<DB::Context const> const&) const ci/tmp/build/./src/Analyzer/QueryTreeBuilder.cpp:514:24
unicode-org#39 0x55a1aba16771 in DB::(anonymous namespace)::QueryTreeBuilder::buildWindow(std::__1::shared_ptr<DB::IAST> const&, std::__1::shared_ptr<DB::Context const> const&) const ci/tmp/build/./src/Analyzer/QueryTreeBuilder.cpp:818:41
unicode-org#40 0x55a1ab9f06ab in DB::(anonymous namespace)::QueryTreeBuilder::buildExpression(std::__1::shared_ptr<DB::IAST> const&, std::__1::shared_ptr<DB::Context const> const&) const ci/tmp/build/./src/Analyzer/QueryTreeBuilder.cpp:708:58
unicode-org#41 0x55a1ab9eb13b in DB::(anonymous namespace)::QueryTreeBuilder::buildExpressionList(std::__1::shared_ptr<DB::IAST> const&, std::__1::shared_ptr<DB::Context const> const&) const ci/tmp/build/./src/Analyzer/QueryTreeBuilder.cpp:588:32
unicode-org#42 0x55a1aba004f7 in DB::(anonymous namespace)::QueryTreeBuilder::buildSelectExpression(std::__1::shared_ptr<DB::IAST> const&, bool, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>> const&, std::__1::shared_ptr<DB::IAST> const&, std::__1::shared_ptr<DB::Context const> const&) const ci/tmp/build/./src/Analyzer/QueryTreeBuilder.cpp:339:51
unicode-org#43 0x55a1ab9e8ec9 in DB::(anonymous namespace)::QueryTreeBuilder::buildSelectOrUnionExpression(std::__1::shared_ptr<DB::IAST> const&, bool, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>> const&, std::__1::shared_ptr<DB::IAST> const&, std::__1::shared_ptr<DB::Context const> const&) const ci/tmp/build/./src/Analyzer/QueryTreeBuilder.cpp:162:22
unicode-org#44 0x55a1ab9f4620 in DB::(anonymous namespace)::QueryTreeBuilder::buildSelectWithUnionExpression(std::__1::shared_ptr<DB::IAST> const&, bool, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>> const&, std::__1::shared_ptr<DB::IAST> const&, std::__1::shared_ptr<DB::Context const> const&) const ci/tmp/build/./src/Analyzer/QueryTreeBuilder.cpp:180:16
unicode-org#45 0x55a1ab9e8bc1 in DB::(anonymous namespace)::QueryTreeBuilder::buildSelectOrUnionExpression(std::__1::shared_ptr<DB::IAST> const&, bool, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>> const&, std::__1::shared_ptr<DB::IAST> const&, std::__1::shared_ptr<DB::Context const> const&) const ci/tmp/build/./src/Analyzer/QueryTreeBuilder.cpp:158:22
unicode-org#46 0x55a1ab9e5a21 in DB::(anonymous namespace)::QueryTreeBuilder::buildQueryTreeNode(std::__1::shared_ptr<DB::IAST>, std::__1::shared_ptr<DB::Context const>) ci/tmp/build/./src/Analyzer/QueryTreeBuilder.cpp:140:27
unicode-org#47 0x55a1ab9e5a21 in DB::buildQueryTree(std::__1::shared_ptr<DB::IAST>, std::__1::shared_ptr<DB::Context const>) ci/tmp/build/./src/Analyzer/QueryTreeBuilder.cpp:1161:20
unicode-org#48 0x55a1aefdac0d in DB::buildQueryTreeAndRunPasses(std::__1::shared_ptr<DB::IAST> const&, DB::SelectQueryOptions const&, std::__1::shared_ptr<DB::Context const> const&, std::__1::shared_ptr<DB::IStorage> const&) ci/tmp/build/./src/Interpreters/InterpreterSelectQueryAnalyzer.cpp:153:23
unicode-org#49 0x55a1aefd3f6d in DB::InterpreterSelectQueryAnalyzer::InterpreterSelectQueryAnalyzer(std::__1::shared_ptr<DB::IAST> const&, std::__1::shared_ptr<DB::Context const> const&, DB::SelectQueryOptions const&, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>>> const&) ci/tmp/build/./src/Interpreters/InterpreterSelectQueryAnalyzer.cpp:182:18
unicode-org#50 0x55a1aefde9f1 in std::__1::unique_ptr<DB::InterpreterSelectQueryAnalyzer, std::__1::default_delete<DB::InterpreterSelectQueryAnalyzer>> std::__1::make_unique[abi:ne210105]<DB::InterpreterSelectQueryAnalyzer, std::__1::shared_ptr<DB::IAST>&, std::__1::shared_ptr<DB::Context> const&, DB::SelectQueryOptions const&, 0>(std::__1::shared_ptr<DB::IAST>&, std::__1::shared_ptr<DB::Context> const&, DB::SelectQueryOptions const&) ci/tmp/build/./contrib/llvm-project/libcxx/include/__memory/unique_ptr.h:759:30
unicode-org#51 0x55a1aefde4d2 in DB::registerInterpreterSelectQueryAnalyzer(DB::InterpreterFactory&)::$_0::operator()(DB::InterpreterFactory::Arguments const&) const ci/tmp/build/./src/Interpreters/InterpreterSelectQueryAnalyzer.cpp:307:16
unicode-org#52 0x55a1aefde4d2 in decltype(std::declval<DB::registerInterpreterSelectQueryAnalyzer(DB::InterpreterFactory&)::$_0&>()(std::declval<DB::InterpreterFactory::Arguments const&>())) std::__1::__invoke[abi:ne210105]<DB::registerInterpreterSelectQueryAnalyzer(DB::InterpreterFactory&)::$_0&, DB::InterpreterFactory::Arguments const&>(DB::registerInterpreterSelectQueryAnalyzer(DB::InterpreterFactory&)::$_0&, DB::InterpreterFactory::Arguments const&) ci/tmp/build/./contrib/llvm-project/libcxx/include/__type_traits/invoke.h:249:25
unicode-org#53 0x55a1aefde4d2 in std::__1::unique_ptr<DB::IInterpreter, std::__1::default_delete<DB::IInterpreter>> std::__1::__invoke_void_return_wrapper<std::__1::unique_ptr<DB::IInterpreter, std::__1::default_delete<DB::IInterpreter>>, false>::__call[abi:ne210105]<DB::registerInterpreterSelectQueryAnalyzer(DB::InterpreterFactory&)::$_0&, DB::InterpreterFactory::Arguments const&>(DB::registerInterpreterSelectQueryAnalyzer(DB::InterpreterFactory&)::$_0&, DB::InterpreterFactory::Arguments const&) ci/tmp/build/./contrib/llvm-project/libcxx/include/__type_traits/invoke.h:334:12
unicode-org#54 0x55a1aefde4d2 in std::__1::unique_ptr<DB::IInterpreter, std::__1::default_delete<DB::IInterpreter>> std::__1::__invoke_r[abi:ne210105]<std::__1::unique_ptr<DB::IInterpreter, std::__1::default_delete<DB::IInterpreter>>, DB::registerInterpreterSelectQueryAnalyzer(DB::InterpreterFactory&)::$_0&, DB::InterpreterFactory::Arguments const&>(DB::registerInterpreterSelectQueryAnalyzer(DB::InterpreterFactory&)::$_0&, DB::InterpreterFactory::Arguments const&) ci/tmp/build/./contrib/llvm-project/libcxx/include/__type_traits/invoke.h:348:10
unicode-org#55 0x55a1aefde4d2 in std::__1::unique_ptr<DB::IInterpreter, std::__1::default_delete<DB::IInterpreter>> std::__1::__function::__policy_func<std::__1::unique_ptr<DB::IInterpreter, std::__1::default_delete<DB::IInterpreter>> (DB::InterpreterFactory::Arguments const&)>::__call_func[abi:ne210105]<DB::registerInterpreterSelectQueryAnalyzer(DB::InterpreterFactory&)::$_0>(std::__1::__function::__policy_storage const*, DB::InterpreterFactory::Arguments const&) ci/tmp/build/./contrib/llvm-project/libcxx/include/__functional/function.h:450:12
unicode-org#56 0x55a1aee07b17 in std::__1::__function::__policy_func<std::__1::unique_ptr<DB::IInterpreter, std::__1::default_delete<DB::IInterpreter>> (DB::InterpreterFactory::Arguments const&)>::operator()[abi:ne210105](DB::InterpreterFactory::Arguments const&) const ci/tmp/build/./contrib/llvm-project/libcxx/include/__functional/function.h:508:12
unicode-org#57 0x55a1aee07b17 in std::__1::function<std::__1::unique_ptr<DB::IInterpreter, std::__1::default_delete<DB::IInterpreter>> (DB::InterpreterFactory::Arguments const&)>::operator()(DB::InterpreterFactory::Arguments const&) const ci/tmp/build/./contrib/llvm-project/libcxx/include/__functional/function.h:772:10
unicode-org#58 0x55a1aee07b17 in DB::InterpreterFactory::get(std::__1::shared_ptr<DB::IAST>&, std::__1::shared_ptr<DB::Context>, DB::SelectQueryOptions const&) ci/tmp/build/./src/Interpreters/InterpreterFactory.cpp:398:12
unicode-org#59 0x55a1afc33e94 in DB::executeQueryImpl(char const*, char const*, std::__1::shared_ptr<DB::Context>, DB::QueryFlags, DB::QueryProcessingStage::Enum, std::__1::unique_ptr<DB::ReadBuffer, std::__1::default_delete<DB::ReadBuffer>>&, std::__1::shared_ptr<DB::IAST>&, std::__1::shared_ptr<DB::ImplicitTransactionControlExecutor>, std::__1::function<void ()>, DB::QueryResultDetails&) ci/tmp/build/./src/Interpreters/executeQuery.cpp:1545:66
unicode-org#60 0x55a1afc24152 in DB::executeQuery(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>> const&, std::__1::shared_ptr<DB::Context>, DB::QueryFlags, DB::QueryProcessingStage::Enum) ci/tmp/build/./src/Interpreters/executeQuery.cpp:1833:11
unicode-org#61 0x55a1befed98c in DB::TCPHandler::runImpl() ci/tmp/build/./src/Server/TCPHandler.cpp:765:68
unicode-org#62 0x55a1bf06214d in DB::TCPHandler::run() ci/tmp/build/./src/Server/TCPHandler.cpp:2861:9
unicode-org#63 0x55a1cc727d1f in Poco::Net::TCPServerConnection::start() ci/tmp/build/./base/poco/Net/src/TCPServerConnection.cpp:40:3
unicode-org#64 0x55a1cc728d11 in Poco::Net::TCPServerDispatcher::run() ci/tmp/build/./base/poco/Net/src/TCPServerDispatcher.cpp:115:38
unicode-org#65 0x55a1cc5cfbb4 in Poco::PooledThread::run() ci/tmp/build/./base/poco/Foundation/src/ThreadPool.cpp:205:14
unicode-org#66 0x55a1cc5cc06d in Poco::(anonymous namespace)::RunnableHolder::run() ci/tmp/build/./base/poco/Foundation/src/Thread.cpp:45:11
unicode-org#67 0x55a1cc5c8ad0 in Poco::ThreadImpl::runnableEntry(void*) ci/tmp/build/./base/poco/Foundation/src/Thread_POSIX.cpp:341:27
unicode-org#68 0x7f33ed519ac2 (/lib/x86_64-linux-gnu/libc.so.6+0x94ac2) (BuildId: 4f7b0c955c3d81d7cac1501a2498b69d1d82bfe7)
unicode-org#69 0x7f33ed5ab8bf (/lib/x86_64-linux-gnu/libc.so.6+0x1268bf) (BuildId: 4f7b0c955c3d81d7cac1501a2498b69d1d82bfe7)
Member fields were destroyed
#0 0x55a17b0a66fd in __sanitizer_dtor_callback_fields (/home/ubuntu/actions-runner/_work/ClickHouse/ClickHouse/ci/tmp/clickhouse+0xa57c6fd) (BuildId: 90b99d5bc334c7128a6e1b564bd565effb9cdf11)
ClickHouse#1 0x55a1c49b6243 in icu_78::Locale::Heap::~Heap() ci/tmp/build/./contrib/icu/icu4c/source/common/unicode/locid.h:1234:21
ClickHouse#2 0x55a1c49b6243 in icu_78::Locale::Heap::~Heap() ci/tmp/build/./contrib/icu/icu4c/source/common/locid.cpp:346:1
ClickHouse#3 0x55a1c49b68f2 in icu_78::Locale::Payload::~Payload() ci/tmp/build/./contrib/icu/icu4c/source/common/locid.cpp:404:31
unicode-org#4 0x55a1c49bf4fd in icu_78::Locale::Nest& icu_78::Locale::Payload::emplace<icu_78::Locale::Nest, icu_78::Locale::Heap, unsigned char>(icu_78::Locale::Heap&&, unsigned char&&) ci/tmp/build/./contrib/icu/icu4c/source/common/locid.cpp:433:15
unicode-org#5 0x55a1c49bf4fd in icu_78::Locale::setKeywordValue(icu_78::StringPiece, icu_78::StringPiece, UErrorCode&) ci/tmp/build/./contrib/icu/icu4c/source/common/locid.cpp:2799:33
unicode-org#6 0x55a1c4996b63 in icu_78::Locale::setKeywordValue(char const*, char const*, UErrorCode&) ci/tmp/build/./contrib/icu/icu4c/source/common/unicode/locid.h:745:9
unicode-org#7 0x55a1c4998a8b in icu_78::CollationLoader::loadFromData(UErrorCode&) ci/tmp/build/./contrib/icu/icu4c/source/i18n/ucol_res.cpp:452:25
unicode-org#8 0x55a1c4995fcc in icu_78::CollationLoader::createCacheEntry(UErrorCode&) ci/tmp/build/./contrib/icu/icu4c/source/i18n/ucol_res.cpp:233:16
unicode-org#9 0x55a1c4995fcc in icu_78::LocaleCacheKey<icu_78::CollationCacheEntry>::createObject(void const*, UErrorCode&) const ci/tmp/build/./contrib/icu/icu4c/source/i18n/ucol_res.cpp:144:20
unicode-org#10 0x55a1c4b023e3 in icu_78::UnifiedCache::_get(icu_78::CacheKeyBase const&, icu_78::SharedObject const*&, void const*, UErrorCode&) const ci/tmp/build/./contrib/icu/icu4c/source/common/unifiedcache.cpp:394:17
unicode-org#11 0x55a1c49963c7 in void icu_78::UnifiedCache::get<icu_78::CollationCacheEntry>(icu_78::CacheKey<icu_78::CollationCacheEntry> const&, void const*, icu_78::CollationCacheEntry const*&, UErrorCode&) const ci/tmp/build/./contrib/icu/icu4c/source/common/unifiedcache.h:234:8
unicode-org#12 0x55a1c49963c7 in icu_78::CollationLoader::getCacheEntry(UErrorCode&) ci/tmp/build/./contrib/icu/icu4c/source/i18n/ucol_res.cpp:477:12
unicode-org#13 0x55a1c499800b in icu_78::CollationLoader::loadFromCollations(UErrorCode&) ci/tmp/build/./contrib/icu/icu4c/source/i18n/ucol_res.cpp:383:44
unicode-org#14 0x55a1c4995fea in icu_78::CollationLoader::createCacheEntry(UErrorCode&) ci/tmp/build/./contrib/icu/icu4c/source/i18n/ucol_res.cpp:231:16
unicode-org#15 0x55a1c4995fea in icu_78::LocaleCacheKey<icu_78::CollationCacheEntry>::createObject(void const*, UErrorCode&) const ci/tmp/build/./contrib/icu/icu4c/source/i18n/ucol_res.cpp:144:20
unicode-org#16 0x55a1c4b023e3 in icu_78::UnifiedCache::_get(icu_78::CacheKeyBase const&, icu_78::SharedObject const*&, void const*, UErrorCode&) const ci/tmp/build/./contrib/icu/icu4c/source/common/unifiedcache.cpp:394:17
unicode-org#17 0x55a1c49963c7 in void icu_78::UnifiedCache::get<icu_78::CollationCacheEntry>(icu_78::CacheKey<icu_78::CollationCacheEntry> const&, void const*, icu_78::CollationCacheEntry const*&, UErrorCode&) const ci/tmp/build/./contrib/icu/icu4c/source/common/unifiedcache.h:234:8
unicode-org#18 0x55a1c49963c7 in icu_78::CollationLoader::getCacheEntry(UErrorCode&) ci/tmp/build/./contrib/icu/icu4c/source/i18n/ucol_res.cpp:477:12
unicode-org#19 0x55a1c499776a in icu_78::CollationLoader::loadFromBundle(UErrorCode&) ci/tmp/build/./contrib/icu/icu4c/source/i18n/ucol_res.cpp:309:16
unicode-org#20 0x55a1c4997005 in icu_78::CollationLoader::loadFromLocale(UErrorCode&) ci/tmp/build/./contrib/icu/icu4c/source/i18n/ucol_res.cpp:259:16
unicode-org#21 0x55a1c4995fd6 in icu_78::CollationLoader::createCacheEntry(UErrorCode&) ci/tmp/build/./contrib/icu/icu4c/source/i18n/ucol_res.cpp:227:16
unicode-org#22 0x55a1c4995fd6 in icu_78::LocaleCacheKey<icu_78::CollationCacheEntry>::createObject(void const*, UErrorCode&) const ci/tmp/build/./contrib/icu/icu4c/source/i18n/ucol_res.cpp:144:20
unicode-org#23 0x55a1c4b023e3 in icu_78::UnifiedCache::_get(icu_78::CacheKeyBase const&, icu_78::SharedObject const*&, void const*, UErrorCode&) const ci/tmp/build/./contrib/icu/icu4c/source/common/unifiedcache.cpp:394:17
unicode-org#24 0x55a1c49963c7 in void icu_78::UnifiedCache::get<icu_78::CollationCacheEntry>(icu_78::CacheKey<icu_78::CollationCacheEntry> const&, void const*, icu_78::CollationCacheEntry const*&, UErrorCode&) const ci/tmp/build/./contrib/icu/icu4c/source/common/unifiedcache.h:234:8
unicode-org#25 0x55a1c49963c7 in icu_78::CollationLoader::getCacheEntry(UErrorCode&) ci/tmp/build/./contrib/icu/icu4c/source/i18n/ucol_res.cpp:477:12
unicode-org#26 0x55a1c4996164 in icu_78::CollationLoader::loadTailoring(icu_78::Locale const&, UErrorCode&) ci/tmp/build/./contrib/icu/icu4c/source/i18n/ucol_res.cpp:164:19
unicode-org#27 0x55a1c498046c in icu_78::Collator::makeInstance(icu_78::Locale const&, UErrorCode&) ci/tmp/build/./contrib/icu/icu4c/source/i18n/coll.cpp:468:40
unicode-org#28 0x55a1c498046c in icu_78::Collator::createInstance(icu_78::Locale const&, UErrorCode&) ci/tmp/build/./contrib/icu/icu4c/source/i18n/coll.cpp:449:16
SUMMARY: MemorySanitizer: use-of-uninitialized-value ci/tmp/build/./contrib/llvm-project/libcxx/include/__string/constexpr_c_functions.h:63:10 in unsigned long std::__1::__constexpr_strlen[abi:ne210105]<char>(char const*)
(cherry picked from commit b29faa6)
Not all code paths that allocate memory check/handle OOM errors in the CurrencyPluralInfo class.
Use an internal error code (fInternalStatus) to better report errors during clone and copy construction.