print the correct error code if nfs_mount() fails.

This commit is contained in:
chs 2010-08-08 18:38:31 +00:00
parent 692e1d3085
commit b078ae7e33
1 changed files with 2 additions and 2 deletions

View File

@ -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.
@ -118,7 +118,7 @@ net_open(struct open_file *f, ...)
/* Get the NFS file handle (mountd). */
error = nfs_mount(netdev_sock, rootip, rootpath);
if (error) {
printf("NFS mount error=%d\n", error);
printf("NFS mount error=%d\n", errno);
rootip.s_addr = 0;
fail:
netif_close(netdev_sock);