[libtirpc] don't drop socket lock in krb5p
in 2 other places, we shouldn't have been dropping a socket lock while processing a reply from the server. it lead to race.
This commit is contained in:
parent
f8daa3704a
commit
e63cce53aa
1 changed files with 10 additions and 3 deletions
|
|
@ -625,7 +625,11 @@ call_again:
|
||||||
}
|
}
|
||||||
if (!xdr_getxiddir(xdrs, &ct->reply_msg)) {
|
if (!xdr_getxiddir(xdrs, &ct->reply_msg)) {
|
||||||
if (ct->ct_error.re_status == RPC_SUCCESS) {
|
if (ct->ct_error.re_status == RPC_SUCCESS) {
|
||||||
|
#ifdef NO_CB_4_KRB5P
|
||||||
|
if (cl->cb_thread != INVALID_HANDLE_VALUE)
|
||||||
|
#endif
|
||||||
release_fd_lock(ct->ct_fd, mask);
|
release_fd_lock(ct->ct_fd, mask);
|
||||||
|
SwitchToThread();
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
goto out;
|
goto out;
|
||||||
|
|
@ -656,6 +660,9 @@ call_again:
|
||||||
goto out;
|
goto out;
|
||||||
}
|
}
|
||||||
ct->use_stored_reply_msg = TRUE;
|
ct->use_stored_reply_msg = TRUE;
|
||||||
|
#ifdef NO_CB_4_KRB5P
|
||||||
|
if (cl->cb_thread != INVALID_HANDLE_VALUE)
|
||||||
|
#endif
|
||||||
release_fd_lock(ct->ct_fd, mask);
|
release_fd_lock(ct->ct_fd, mask);
|
||||||
SwitchToThread();
|
SwitchToThread();
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue