diff options
author | Toomas Soome <tsoome@me.com> | 2018-06-14 14:58:47 +0300 |
---|---|---|
committer | Hans Rosenfeld <hans.rosenfeld@joyent.com> | 2018-07-09 18:33:58 +0200 |
commit | 4fa25acac9b3b8878c2f40abbce5443d218b29ea (patch) | |
tree | c984fd55b6a1adbef1244ba64092a11c200af0da /usr/src | |
parent | 692bf522ee0f2281edfe25261f83e5fe71fac37e (diff) | |
download | illumos-joyent-4fa25acac9b3b8878c2f40abbce5443d218b29ea.tar.gz |
9605 loader: initialize variables and remove unused ones
Reviewed by: Yuri Pankov <yuripv@yuripv.net>
Reviewed by: Alexander Eremin <alexander.eremin@nexenta.com>
Approved by: Robert Mustacchi <rm@joyent.com>
Diffstat (limited to 'usr/src')
-rw-r--r-- | usr/src/boot/lib/libstand/nfs.c | 15 |
1 files changed, 7 insertions, 8 deletions
diff --git a/usr/src/boot/lib/libstand/nfs.c b/usr/src/boot/lib/libstand/nfs.c index 1cf8f5af0b..d1a941656f 100644 --- a/usr/src/boot/lib/libstand/nfs.c +++ b/usr/src/boot/lib/libstand/nfs.c @@ -1,6 +1,6 @@ /* $NetBSD: nfs.c,v 1.2 1998/01/24 12:43:09 drochner Exp $ */ -/*- +/* * Copyright (c) 1993 John Brezak * All rights reserved. * @@ -248,7 +248,7 @@ int nfs_lookupfh(struct nfs_iodesc *d, const char *name, struct nfs_iodesc *newfd) { void *pkt = NULL; - int len, rlen, pos; + int len, pos; struct args { uint32_t fhsize; uint32_t fhplusname[1 + @@ -462,27 +462,26 @@ int nfs_open(const char *upath, struct open_file *f) { struct iodesc *desc; - struct nfs_iodesc *currfd; + struct nfs_iodesc *currfd = NULL; char buf[2 * NFS_V3MAXFHSIZE + 3]; u_char *fh; char *cp; int i; - struct nfs_iodesc *newfd; - struct nfsv3_fattrs *fa; + struct nfs_iodesc *newfd = NULL; char *ncp; int c; char namebuf[NFS_MAXPATHLEN + 1]; char linkbuf[NFS_MAXPATHLEN + 1]; int nlinks = 0; int error; - char *path; + char *path = NULL; if (netproto != NET_NFS) return (EINVAL); #ifdef NFS_DEBUG - if (debug) - printf("nfs_open: %s (rootpath=%s)\n", upath, rootpath); + if (debug) + printf("nfs_open: %s (rootpath=%s)\n", upath, rootpath); #endif if (!rootpath[0]) { printf("no rootpath, no nfs\n"); |