Skip to content

Commit

Permalink
Update icu4c/source/common/locbased.cpp
Browse files Browse the repository at this point in the history
Co-authored-by: Markus Scherer <[email protected]>
  • Loading branch information
FrankYFTang and markusicu authored Jan 4, 2025
1 parent 0826aa6 commit 1575d9d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion icu4c/source/common/locbased.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ void LocaleBased::setLocaleID(const char* id, CharString*& dest, UErrorCode& sta

void LocaleBased::setLocaleID(const CharString* id, CharString*& dest, UErrorCode& status) {
if (U_FAILURE(status)) { return; }
if (id == nullptr) {
if (id == nullptr || id->isEmpty()) {
delete dest;
dest = nullptr;
} else {
Expand Down

0 comments on commit 1575d9d

Please sign in to comment.