Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sbin/mount_nfs Handle unsupported protocols (i.e. no v6 supp...
details: https://anonhg.NetBSD.org/src/rev/fa6ec7e80068
branches: trunk
changeset: 488164:fa6ec7e80068
user: fvdl <fvdl%NetBSD.org@localhost>
date: Mon Jun 19 23:19:20 2000 +0000
description:
Handle unsupported protocols (i.e. no v6 support on the other side)
a tad better.
diffstat:
sbin/mount_nfs/mount_nfs.c | 12 ++++++++++--
1 files changed, 10 insertions(+), 2 deletions(-)
diffs (33 lines):
diff -r dfdcc82f3d98 -r fa6ec7e80068 sbin/mount_nfs/mount_nfs.c
--- a/sbin/mount_nfs/mount_nfs.c Mon Jun 19 22:40:17 2000 +0000
+++ b/sbin/mount_nfs/mount_nfs.c Mon Jun 19 23:19:20 2000 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: mount_nfs.c,v 1.25 2000/06/09 00:06:36 fvdl Exp $ */
+/* $NetBSD: mount_nfs.c,v 1.26 2000/06/19 23:19:20 fvdl Exp $ */
/*
* Copyright (c) 1992, 1993, 1994
@@ -46,7 +46,7 @@
#if 0
static char sccsid[] = "@(#)mount_nfs.c 8.11 (Berkeley) 5/4/95";
#else
-__RCSID("$NetBSD: mount_nfs.c,v 1.25 2000/06/09 00:06:36 fvdl Exp $");
+__RCSID("$NetBSD: mount_nfs.c,v 1.26 2000/06/19 23:19:20 fvdl Exp $");
#endif
#endif /* not lint */
@@ -681,6 +681,14 @@
nfs_nb.buf = &nfs_ss;
nfs_nb.maxlen = sizeof nfs_ss;
if (!rpcb_getaddr(RPCPROG_NFS, nfsvers, nconf, &nfs_nb, hostp)){
+ if (rpc_createerr.cf_stat == RPC_SYSTEMERROR) {
+ nfhret.stat = rpc_createerr.cf_error.re_errno;
+ break;
+ }
+ if (rpc_createerr.cf_stat == RPC_UNKNOWNPROTO) {
+ nfhret.stat = EPROTONOSUPPORT;
+ break;
+ }
if ((opflags & ISBGRND) == 0)
clnt_pcreateerror(
"mount_nfs: rpcbind on server:");
Home |
Main Index |
Thread Index |
Old Index