aboutsummaryrefslogtreecommitdiff
path: root/lib/libc/stdio/xprintf_errno.c
Commit message (Collapse)AuthorAgeFilesLines
* libc printf_render_errno(): do not use strerror()Konstantin Belousov2024-04-231-3/+4
| | | | | | | Reviewed by: imp Sponsored by: The FreeBSD Foundation MFC after: 1 week Differential revision: https://reviews.freebsd.org/D44916
* libc: minor style, wrap long linesKonstantin Belousov2024-04-231-2/+4
| | | | | | | Reviewed by: imp Sponsored by: The FreeBSD Foundation MFC after: 1 week Differential revision: https://reviews.freebsd.org/D44916
* Remove $FreeBSD$: two-line .h patternWarner Losh2023-08-161-2/+0
| | | | Remove /^\s*\*\n \*\s+\$FreeBSD\$$\n/
* spdx: The BSD-2-Clause-FreeBSD identifier is obsolete, drop -FreeBSDWarner Losh2023-05-121-1/+1
| | | | | | | | | The SPDX folks have obsoleted the BSD-2-Clause-FreeBSD identifier. Catch up to that fact and revert to their recommended match of BSD-2-Clause. Discussed with: pfg MFC After: 3 days Sponsored by: Netflix
* libc: further adoption of SPDX licensing ID tags.Pedro F. Giffuni2017-11-251-0/+2
| | | | | | | | | | | | | | | Mainly focus on files that use BSD 2-Clause license, however the tool I was using mis-identified many licenses so this was mostly a manual - error prone - task. The Software Package Data Exchange (SPDX) group provides a specification to make it easier for automated tools to detect and summarize well known opensource licenses. We are gradually adopting the specification, noting that the tags are considered only advisory and do not, in any way, superceed or replace the license texts. Notes: svn path=/head/; revision=326193
* libc: Always use our own copy of sys_errlist and sys_nerr (.so only).Jilles Tjoelker2013-08-311-1/+2
| | | | | | | | | | | | | | | | | | This ensures strerror() and friends continue to work correctly even if a (non-PIE) executable linked against an older libc imports sys_errlist (which causes sys_errlist to refer to the executable's copy with a size fixed when that executable was linked). The executable's use of sys_errlist remains broken because it uses the current value of sys_nerr and may access past the bounds of the array. Different from the message "Using sys_errlist from executables is not ABI-stable" on freebsd-arch, this change does not affect the static library. There seems no reason to prevent overriding the error messages in the static library. Notes: svn path=/head/; revision=255108
* Make the %V{is} extension handle a NULL pointer like %s does: output "(null)"Poul-Henning Kamp2006-01-251-0/+65
Add %M{essage} extension which prints an errno value as the corresponding string if possible or numerically otherwise. It is not currently possible to do the syslog(3) like %m extension because errno would need to get capatured on entry to the first function in the printf family, so %M requires you to supply errno as an argument. Add %Q{uote} extension which will print a string in double quotes with appropriate back-slash escapes (only) if necessary. Notes: svn path=/head/; revision=154815