diff options
author | Adhemerval Zanella <adhemerval.zanella@linaro.org> | 2021-01-04 14:26:30 -0300 |
---|---|---|
committer | Adhemerval Zanella <adhemerval.zanella@linaro.org> | 2021-02-23 15:58:04 -0300 |
commit | a79328c745219dcb395070cdcd3be065a8347f24 (patch) | |
tree | 310d500264e2b219d91366544d0053f962a60df2 /csu/libc-start.c | |
parent | 5a664d7ae8e42d641a7b4b436987ff67ab483b08 (diff) | |
download | glibc-a79328c745219dcb395070cdcd3be065a8347f24.tar glibc-a79328c745219dcb395070cdcd3be065a8347f24.tar.gz glibc-a79328c745219dcb395070cdcd3be065a8347f24.tar.bz2 glibc-a79328c745219dcb395070cdcd3be065a8347f24.zip |
posix: Falling back to non wide mode in case of encoding error [BZ #14185]
Gnulib has added the proposed fix with aed23714d60 (done in 2005), but
recently with a glibc merge with 67306f6 (done in 2020 with sync back)
it has fallback to old semantic to return -1 on in case of failure.
From gnulib developer feedback it was an oversight. Although the full
fix for BZ #14185 would require to rewrite fnmatch implementation to use
mbrtowc instead of mbsrtowcs on the full input, this mitigate the issue
and it has been used by gnulib for a long time.
This patch also removes the alloca usage on the string convertion to
wide characters before calling the internal function.
Checked on x86_64-linux-gnu.
Diffstat (limited to 'csu/libc-start.c')
0 files changed, 0 insertions, 0 deletions