Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 27 Jan 1999 14:44:17 -0800 (PST)
From:      Matthew Dillon <dillon@apollo.backplane.com>
To:        current@FreeBSD.ORG
Subject:   bug in nfs_access()
Message-ID:  <199901272244.OAA64912@apollo.backplane.com>

next in thread | raw e-mail | index | archive | help
    bug in nfs_access(). nfs/nfs_vnops.c, line 414 or so.

    Fixed!

    This is a nasty one.  I'm surprised it hasn't caused grief before

					-Matt
					Matthew Dillon 
					<dillon@backplane.com>

		...
                        auio.uio_procp = ap->a_p;
        
                        if (vp->v_type == VREG)
                                error = nfs_readrpc(vp, &auio, ap->a_cred);
                        else if (vp->v_type == VDIR) {
                                char* bp;
                                bp = malloc(NFS_DIRBLKSIZ, M_TEMP, M_WAITOK);
                                aiov.iov_base = bp;
                                aiov.iov_len = auio.uio_resid = NFS_DIRBLKSIZ;
                                error = nfs_readdirrpc(vp, &auio, ap->a_cred);
                                free(bp, M_TEMP);
                        } else if (vp->v_type = VLNK)
                                error = nfs_readlinkrpc(vp, &auio, ap->a_cred);
                        else
                                error = EACCES;



To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-current" in the body of the message



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199901272244.OAA64912>