Pass curthread to various socket routines (socreate(), sobind(), and
soconnect()) instead of &thread0 when establishing a connection to the NFS server. Otherwise inconsistent credentials may be used when setting up the NFS socket. MFC after: 1 week Reviewed by: rwatson
This commit is contained in:
parent
ce309a2f26
commit
0ca54a0fc8
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=175221
@ -264,7 +264,7 @@ nfs_connect(struct nfsmount *nmp, struct nfsreq *rep)
|
||||
int error, rcvreserve, sndreserve;
|
||||
int pktscale;
|
||||
struct sockaddr *saddr;
|
||||
struct thread *td = &thread0; /* only used for socreate and sobind */
|
||||
struct thread *td = curthread; /* only used for socreate and sobind */
|
||||
|
||||
if (nmp->nm_sotype == SOCK_STREAM) {
|
||||
mtx_lock(&nmp->nm_mtx);
|
||||
|
Loading…
Reference in New Issue
Block a user