aboutsummaryrefslogtreecommitdiff
path: root/libgloss/spu/gettimeofday.c
diff options
context:
space:
mode:
authorCorinna Vinschen <corinna@vinschen.de>2026-04-24 12:46:08 +0200
committerCorinna Vinschen <corinna@vinschen.de>2026-04-24 12:46:08 +0200
commit4ba7eff4d15af0f749d1913703a25c045d40fa90 (patch)
tree2b20f73c98c719f63a2379c291569a00667302a6 /libgloss/spu/gettimeofday.c
parent8f1d2b499bc9e8007321090c1859e55c7ce7d417 (diff)
downloadnewlib-main.tar.gz
newlib-main.tar.bz2
newlib-main.zip
jp2uc/up2jc: avoid crash due to invalid pointerHEADgithub/mastergithub/mainmastermain
Commit 4356ccd02c9c ("towupper/towlower: handle Turkic language special casing") changed the locale pointer in calls to towctrans_l from a NULL pointer to LC_GLOBAL_LOCALE, which is defined as -1. Unfortunately jp2uc_l/up2jc_l just expect a NULL or non-NULL pointer, so LC_GLOBAL_LOCALE as input is derefenced later on and the call crashes. To fix this problem, handle LC_GLOBAL_LOCALE just as if a NULL pointer has been passed to the function. Keep the NULL pointer handling intact for backward compatibility. Fixes: 4356ccd02c9c ("towupper/towlower: handle Turkic language special casing") Reported-by: Christophe Lyon <christophe.lyon.oss@gmail.com> Signed-off-by: Corinna Vinschen <corinna@vinschen.de>
Diffstat (limited to 'libgloss/spu/gettimeofday.c')
0 files changed, 0 insertions, 0 deletions