Commit f4fdb352 authored by David Howells's avatar David Howells

rxrpc: Use call->peer rather than call->conn->params.peer

Use call->peer rather than call->conn->params.peer to avoid the possibility
of call->conn being NULL and, whilst we're at it, check it for NULL before we
access it.
Signed-off-by: default avatarDavid Howells <dhowells@redhat.com>
parent fff72429
......@@ -514,9 +514,11 @@ void rxrpc_release_call(struct rxrpc_call *call)
*/
_debug("RELEASE CALL %p (%d CONN %p)", call, call->debug_id, conn);
spin_lock(&conn->params.peer->lock);
hlist_del_init(&call->error_link);
spin_unlock(&conn->params.peer->lock);
if (call->peer) {
spin_lock(&call->peer->lock);
hlist_del_init(&call->error_link);
spin_unlock(&call->peer->lock);
}
write_lock_bh(&rx->call_lock);
if (!list_empty(&call->accept_link)) {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment