msvcrt: Check locale for NULL before freeing.
This commit is contained in:
parent
c6e5e39460
commit
27a28bf29f
|
@ -576,6 +576,9 @@ void CDECL MSVCRT__free_locale(MSVCRT__locale_t locale)
|
|||
{
|
||||
int i;
|
||||
|
||||
if (!locale)
|
||||
return;
|
||||
|
||||
for(i=MSVCRT_LC_MIN+1; i<=MSVCRT_LC_MAX; i++) {
|
||||
MSVCRT_free(locale->locinfo->lc_category[i].locale);
|
||||
MSVCRT_free(locale->locinfo->lc_category[i].refcount);
|
||||
|
|
Loading…
Reference in New Issue