freebsd-dev/usr.bin/printf
Jilles Tjoelker 342b089bca printf: Output formatted data directly, instead of via asprintf.
Long ago, sh used to have its own optimized and restricted string formatting
implementation, which the printf builtin had to bypass via asprintf() to a
temporary buffer. Since sh has used libc's string formatting implementation
for a long time, remove the workaround.

Add a check to keep  printf %c ''  working the same way (output nothing);
POSIX allows both outputting nothing and outputting a NUL byte.

Also, this change avoids silently discarding format directives for whose
output asprintf() cannot allocate memory.
2017-04-29 21:48:11 +00:00
..
tests Merge ^/user/ngie/release-pkg-fix-tests to unbreak how test files are installed 2016-05-04 23:20:53 +00:00
Makefile Use src.opts.mk in preference to bsd.own.mk except where we need stuff 2014-05-06 04:22:01 +00:00
Makefile.depend Add META_MODE support. 2015-06-13 19:20:56 +00:00
printf.1 Renumber copyright clause 4 2017-02-28 23:42:47 +00:00
printf.c printf: Output formatted data directly, instead of via asprintf. 2017-04-29 21:48:11 +00:00