diff options
author | Rich Felker <dalias@aerifal.cx> | 2012-08-15 22:35:02 -0400 |
---|---|---|
committer | Rich Felker <dalias@aerifal.cx> | 2012-08-15 22:35:02 -0400 |
commit | dc82ee4e30ec0eae367f7ab076a7325b4d858dd5 (patch) | |
tree | 5929b61b532ea22203904c57ddf3e87af36225ce /src/linux/err.c | |
parent | 3f80afc50577dada3940b66ef5b67da2f43cc00a (diff) | |
download | musl-dc82ee4e30ec0eae367f7ab076a7325b4d858dd5.tar.gz musl-dc82ee4e30ec0eae367f7ab076a7325b4d858dd5.tar.xz musl-dc82ee4e30ec0eae367f7ab076a7325b4d858dd5.zip |
handle null arguments to legacy bsd err.h functions
Diffstat (limited to 'src/linux/err.c')
-rw-r--r-- | src/linux/err.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/linux/err.c b/src/linux/err.c index abc26806..c291136d 100644 --- a/src/linux/err.c +++ b/src/linux/err.c @@ -5,13 +5,13 @@ void vwarn(const char *fmt, va_list ap) { - vfprintf(stderr, fmt, ap); + if (fmt) vfprintf(stderr, fmt, ap); perror(""); } void vwarnx(const char *fmt, va_list ap) { - vfprintf(stderr, fmt, ap); + if (fmt) vfprintf(stderr, fmt, ap); putc('\n', stderr); } |