json-glib: update to 1.10.6
[oi-userland.git] / components / library / icu / patches / 133-source-i18n-region.cpp.patch
blob2d24ffe2459401109352c25323cd49d6fb0e7a8f
2 # Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved.
4 prevent a null pointer dereference
6 --- icu/source/i18n/region.cpp.orig
7 +++ icu/source/i18n/region.cpp
8 @@ -510,6 +510,10 @@
10 if ( r->fType == URGN_DEPRECATED && r->preferredValues->size() == 1) {
11 StringEnumeration *pv = r->getPreferredValues(status);
12 + if ( U_FAILURE(status) ) {
13 + delete r;
14 + return nullptr;
15 + }
16 pv->reset(status);
17 const UnicodeString *ustr = pv->snext(status);
18 r = static_cast<Region*>(uhash_get(regionIDMap, ustr));