diff options
author | 2014-05-20 01:25:23 +0000 | |
---|---|---|
committer | 2014-05-20 01:25:23 +0000 | |
commit | 5ad04d351680822078003e2b066cfc9680d6157d (patch) | |
tree | bc78d1cc74e659478aa86d8884efcb9a0d678e50 /usr.bin/grep | |
parent | Bring UTF8_{getc,putc} up-to-date: it's been a decade since 5- and 6-byte (diff) | |
download | wireguard-openbsd-5ad04d351680822078003e2b066cfc9680d6157d.tar.xz wireguard-openbsd-5ad04d351680822078003e2b066cfc9680d6157d.zip |
Use errc/warnc to simplify code.
Also, in 'ftp', always put the error message last, after the hostname/ipaddr.
ok jsing@ krw@ millert@
Diffstat (limited to 'usr.bin/grep')
-rw-r--r-- | usr.bin/grep/util.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/usr.bin/grep/util.c b/usr.bin/grep/util.c index 33dc25e392d..bc132f57746 100644 --- a/usr.bin/grep/util.c +++ b/usr.bin/grep/util.c @@ -1,4 +1,4 @@ -/* $OpenBSD: util.c,v 1.47 2013/11/26 13:21:16 deraadt Exp $ */ +/* $OpenBSD: util.c,v 1.48 2014/05/20 01:25:23 guenther Exp $ */ /*- * Copyright (c) 1999 James Howard and Dag-Erling Coïdan Smørgrav @@ -74,7 +74,7 @@ grep_tree(char **argv) case FTS_ERR: file_err = 1; if(!sflag) - warnx("%s: %s", p->fts_path, strerror(p->fts_errno)); + warnc(p->fts_errno, "%s", p->fts_path); break; case FTS_DP: break; |