diff options
author | cem <cem@FreeBSD.org> | 2015-07-22 22:53:40 +0000 |
---|---|---|
committer | cem <cem@FreeBSD.org> | 2015-07-22 22:53:40 +0000 |
commit | a5167194cfa26070d6165b2e9569bf50a8d2676a (patch) | |
tree | c84e79b928d6077173ca09e7a7c5d0f7bc63b07c /sbin | |
parent | aa7795c019c10b3f52cf18fc3553604e1b5ec7cb (diff) | |
download | FreeBSD-src-a5167194cfa26070d6165b2e9569bf50a8d2676a.zip FreeBSD-src-a5167194cfa26070d6165b2e9569bf50a8d2676a.tar.gz |
mount_nfs: Be more clear on nmount(2) error with errmsg unset
Differential Revision: https://reviews.freebsd.org/D3147
Reviewed by: rmacklem
Approved by: markj (mentor)
MFC after: 2 weeks
Sponsored by: EMC / Isilon Storage Division
Diffstat (limited to 'sbin')
-rw-r--r-- | sbin/mount_nfs/mount_nfs.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/sbin/mount_nfs/mount_nfs.c b/sbin/mount_nfs/mount_nfs.c index 836bc87..810cf59 100644 --- a/sbin/mount_nfs/mount_nfs.c +++ b/sbin/mount_nfs/mount_nfs.c @@ -476,7 +476,8 @@ main(int argc, char *argv[]) build_iovec(&iov, &iovlen, "errmsg", errmsg, sizeof(errmsg)); if (nmount(iov, iovlen, 0)) - err(1, "%s, %s", mntpath, errmsg); + err(1, "nmount: %s%s%s", mntpath, errmsg[0] ? ", " : "", + errmsg); exit(0); } |