print the correct error code if nfs_mount() fails.
This commit is contained in:
parent
692e1d3085
commit
b078ae7e33
|
@ -1,4 +1,4 @@
|
||||||
/* $NetBSD: dev_net.c,v 1.24 2009/01/17 14:00:36 tsutsui Exp $ */
|
/* $NetBSD: dev_net.c,v 1.25 2010/08/08 18:38:31 chs Exp $ */
|
||||||
|
|
||||||
/*-
|
/*-
|
||||||
* Copyright (c) 1997 The NetBSD Foundation, Inc.
|
* Copyright (c) 1997 The NetBSD Foundation, Inc.
|
||||||
|
@ -118,7 +118,7 @@ net_open(struct open_file *f, ...)
|
||||||
/* Get the NFS file handle (mountd). */
|
/* Get the NFS file handle (mountd). */
|
||||||
error = nfs_mount(netdev_sock, rootip, rootpath);
|
error = nfs_mount(netdev_sock, rootip, rootpath);
|
||||||
if (error) {
|
if (error) {
|
||||||
printf("NFS mount error=%d\n", error);
|
printf("NFS mount error=%d\n", errno);
|
||||||
rootip.s_addr = 0;
|
rootip.s_addr = 0;
|
||||||
fail:
|
fail:
|
||||||
netif_close(netdev_sock);
|
netif_close(netdev_sock);
|
||||||
|
|
Loading…
Reference in New Issue