Age | Commit message (Collapse) | Author |
|
ok millert@
|
|
and when the file ends without a terminating Ln character,
fgetws(3) discarded any characters read and reported bogus EOF.
Never inspect errno(2) unless right after an error occurred!
OK millert@
|
|
1. When fprintf(fp, "...%ls...", ...) encounters an encoding error,
do not destroy all the fp->_flags, which made the file permanently
unreadable and unwriteable.
2. Do not change fp->_flags at all in case of encoding errors.
Neither the manual nor POSIX ask for it, no other conversions set the
error indicator, and it isn't needed because the return value reports
failure and must be checked anyway.
3. Detect failure in mbrtowc(3), do not silently treat invalid bytes
in the format string as the end of the format string.
4. Detect failure of __find_arguments(), no matter whether due to
out of memory conditions or encoding errors, and gracefully fail
rather than accessing an invalid pointer.
5. Remove the pointless and slightly dangerous errno = EILSEQ overrides
after functions that already do that and are required by the standard
to do so.
OK jca@ on items 1, 2, and 5.
OK millert@ on the complete diff.
"Completely brutal mix of bugs." deraadt@
|
|
ok and valuable input from millert@
|
|
encoding error occurs, so do it.
While here, do not set errno after mbrtowc(3) failure; mbrtowc(3)
already does that, and that behaviour is required by the standard.
ok jca@ guenther@ "nice find" deraadt@
|
|
|
|
Wrap __cxa_{atexit,finalize}() so the call from exit() goes direct
Switch regress/lib/libc/atexit/ to be built with -static so that it can
still access __atexit*
ok millert@ jca@
|
|
these functions return a negative value on failure.
OK doug@ deraadt@
|
|
and show this in the example.
|
|
exporting it)
|
|
case, by deleting some useless '& of an array' we also eliminate the need
for the casts which prompted the original lint warnings
ok deraadt@
|
|
ok millert@
|
|
|
|
|
|
C standard are all weak.
Apply __{BEGIN,END}_HIDDEN_DECLS to gdtoa{,imp}.h, hiding the
arch-specific __strtorx, __ULtox_D2A, __strtorQ, __ULtoQ_D2A symbols.
|
|
and the symbols not in the C standard are weak
|
|
Delete unused 'fd' argument from internal function oldttyname()
|
|
|
|
wrapper .h files and asm labels to let internal calls resolve directly and
not be overridable or use the PLT. Then, apply that framework to most of
the functions in stdio.h, string.h, err.h, and wchar.h. Delete the
should-have-been-hidden-all-along _v?(err|warn)[cx]? symbols while here.
tests clean on i386, amd64, sparc64, powerpc, and mips64
naming feedback from kettenis@ and millert@
ok kettenis@
|
|
symbols that are not longer exported. (This improves the generated code.)
ok deraadt@
|
|
malloc/calloc/realloc* returns.
|
|
available on more systems these days. OK deraadt@
|
|
ok miod@ millert@ krw@ guenther@
|
|
"and" and "or" to join sentence clauses, and you can use commas, but both hinders
reading;
|
|
From Ryan May.
|
|
time. Prodded by guenther@. Sorry.
|
|
|
|
Predefined strings are not very portable across troff implementations,
and they make the source much harder to read. Usually the intended
character can be written directly.
No output changes, except for two instances where the incorrect escape
was used in the first place.
tweaks + ok schwarze@
|
|
obsolete SIZE_T_MAX. OK miod@ beck@
|
|
|
|
remove .Tn, and a few minor macro adjustments.
Patch from Kaspars at Bankovskis dot net.
|
|
review by millert, binary checking process with doug, concept with guenther
|
|
|
|
|
|
instead where necessary.
Based on a diff from enh (at) google.com
ok millert@
|
|
|
|
API to NUL-terminate the buffer.
|
|
ok martynas@, millert@, doug@
|
|
from enh at google
|
|
|
|
|
|
that it returns an error for invalid mode which matches our behavior.
OK jmc@ deraadt@
|
|
should be used in new code.
|
|
|
|
troff displays these as typographic quotes, but nroff implementations
almost always print them literally, which rarely has the intended effect
with modern fonts, even in stock xterm.
These uses of `` '' can be replaced either with more semantic alternatives
or with Dq, which prints typographic quotes in a UTF-8 locale (but will
automatically fall back to `` '' in an ASCII locale).
improvements and ok schwarze@
|
|
|
|
Since tempchars is never reassigned there's no need to indirect
through a pointer. Still getting used to this newfangled C89.
|
|
for consistency with the rest of the manual.
|
|
OK deraadt@
|
|
ok doug
|