X-Git-Url: https://git.saurik.com/apple/xnu.git/blobdiff_plain/bca245acd4c03fd752d1a45f011ad495e60fe53d..eb6b6ca394357805f2bdba989abae309f718b4d8:/bsd/nfs/nfs_socket.c diff --git a/bsd/nfs/nfs_socket.c b/bsd/nfs/nfs_socket.c index e5c2a590e..b0fad27f1 100644 --- a/bsd/nfs/nfs_socket.c +++ b/bsd/nfs/nfs_socket.c @@ -1799,23 +1799,21 @@ keepsearching: if (!NFS_BITMAP_ISSET(nmp->nm_mattrs, NFS_MATTR_SOCKET_TYPE)) { nmp->nm_sotype = 0; } - if (!NFS_BITMAP_ISSET(nmp->nm_mattrs, NFS_MATTR_NFS_VERSION)) { #if CONFIG_NFS4 - if (nmp->nm_vers >= NFS_VER4) { - if (!NFS_BITMAP_ISSET(nmp->nm_mattrs, NFS_MATTR_NFS_PORT)) { - nmp->nm_nfsport = 0; - } - if (nmp->nm_cbid) { - nfs4_mount_callback_shutdown(nmp); - } - if (IS_VALID_CRED(nmp->nm_mcred)) { - kauth_cred_unref(&nmp->nm_mcred); - } - bzero(&nmp->nm_un, sizeof(nmp->nm_un)); + if (nmp->nm_vers >= NFS_VER4) { + if (!NFS_BITMAP_ISSET(nmp->nm_mattrs, NFS_MATTR_NFS_PORT)) { + nmp->nm_nfsport = 0; } -#endif - nmp->nm_vers = 0; + if (nmp->nm_cbid) { + nfs4_mount_callback_shutdown(nmp); + } + if (IS_VALID_CRED(nmp->nm_mcred)) { + kauth_cred_unref(&nmp->nm_mcred); + } + bzero(&nmp->nm_un, sizeof(nmp->nm_un)); } +#endif + nmp->nm_vers = 0; } lck_mtx_unlock(&nmp->nm_lock); nmp->nm_nso = NULL;