4
0
mirror of git://sourceware.org/git/newlib-cygwin.git synced 2025-02-22 16:49:45 +08:00
Takashi Yano bc986b7ff6 stdio: Fix bugs in commit 3d94e07c49b5
The commit 3d94e07c49b5 has a few bugs which cause testsuite failure
in libstdc++. This is due to excess orientation check in __srefill_r()
and _ungetc_r(). Further, sscanf() family also calls ssvfscanf() family
with fp->_file == -1. This causes undesired orientation set/check for
sscanf() family. This patch fixes these problems.

Also, as in GLibC, do not set orientation in ungetc, and only set, but
do not check orientation in ungetwc.

Fixes: 3d94e07c49b5 ("newlib: libc: Fix crash on fprintf to a wide-oriented stream.")
Reported-by: Christophe Lyon <christophe.lyon@linaro.org>
Reported-by: Joel Sherrill <joel@rtems.org>
Co-developed-by: Corinna Vinschen <corinna@vinschen.de>
Signed-off-by: Takashi Yano <takashi.yano@nifty.ne.jp>
Signed-off-by: Corinna Vinschen <corinna@vinschen.de>
2023-11-20 20:59:12 +01:00
..
2018-01-17 11:47:26 -06:00
2018-01-17 11:47:26 -06:00
2022-07-13 06:55:41 +02:00
2018-01-17 11:47:26 -06:00
2018-01-17 11:47:26 -06:00
2022-07-13 06:55:41 +02:00
2018-01-17 11:47:26 -06:00
2022-07-13 06:55:41 +02:00
2022-07-13 06:55:41 +02:00
2022-07-13 06:55:41 +02:00
2022-07-13 06:55:41 +02:00
2022-07-13 06:55:41 +02:00
2022-07-13 06:55:41 +02:00
2018-01-17 11:47:26 -06:00
2022-07-13 06:55:41 +02:00
2022-07-13 06:55:41 +02:00
2018-01-17 11:47:26 -06:00
2022-07-13 06:55:41 +02:00
2022-07-13 06:55:41 +02:00
2022-07-13 06:55:41 +02:00
2018-01-17 11:47:26 -06:00
2023-11-20 20:59:12 +01:00
2018-01-17 11:47:26 -06:00
2018-01-17 11:47:26 -06:00
2018-01-17 11:47:26 -06:00
2018-01-17 11:47:26 -06:00
2018-01-17 11:47:26 -06:00
2022-07-13 06:55:41 +02:00
2018-01-17 11:47:08 -06:00
2022-07-13 06:55:41 +02:00
2018-01-17 11:47:13 -06:00
2022-07-13 06:55:41 +02:00
2022-07-13 06:55:41 +02:00
2018-01-17 11:47:26 -06:00
2018-01-17 11:47:26 -06:00
2018-01-17 11:47:26 -06:00
2018-01-17 11:47:26 -06:00
2022-07-13 06:55:46 +02:00
2018-01-17 11:47:26 -06:00
2022-07-13 06:55:41 +02:00
2018-01-17 11:47:26 -06:00
2017-04-18 12:25:35 +02:00
2022-08-31 15:18:08 -04:00
2022-07-13 06:55:41 +02:00