]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
MFC r304607,r304641,r304819,r304811
authorache <ache@FreeBSD.org>
Sat, 27 Aug 2016 10:34:01 +0000 (10:34 +0000)
committerache <ache@FreeBSD.org>
Sat, 27 Aug 2016 10:34:01 +0000 (10:34 +0000)
commit7767fddf9fce411b32f1cc6cc3b725dc57dead47
treeec303e5e12bcee42a6b93b2ab65b9c4ba65faba5
parentd5deef2805b5b8f2ca41fbe42c1456e9ab6a2534
MFC r304607,r304641,r304819,r304811

1) Don't forget to set __SERR on __slbexpand() error.

2) Remove "Fast path" from fgetwc()/fputwc() since it can't detect
encoding errors and ignores them all.
One of affected encoding example: US-ASCII

3)  Original fgetln() from 44lite return success for line tail errors,
i.e. partial line, but set __SERR and errno in the same time, which
is inconsistent.
Now both OpenBSD and NetBSD return failure, i.e. no line and set error
indicators for such case, so make our fgetln() and fgetwln()
(as its wide version) compatible with the rest of *BSD.

PR:     212033
lib/libc/stdio/fgetln.c
lib/libc/stdio/fgetwc.c
lib/libc/stdio/fgetwln.c
lib/libc/stdio/fputwc.c