Commit 7212a57e authored by David Howells's avatar David Howells

rxrpc: Fix oops on incoming call to serviceless endpoint

If an call comes in to a local endpoint that isn't listening for any
incoming calls at the moment, an oops will happen.  We need to check that
the local endpoint's service pointer isn't NULL before we dereference it.
Signed-off-by: default avatarDavid Howells <dhowells@redhat.com>
parent 19c0dbd5
...@@ -337,7 +337,7 @@ struct rxrpc_call *rxrpc_new_incoming_call(struct rxrpc_local *local, ...@@ -337,7 +337,7 @@ struct rxrpc_call *rxrpc_new_incoming_call(struct rxrpc_local *local,
/* Get the socket providing the service */ /* Get the socket providing the service */
rx = rcu_dereference(local->service); rx = rcu_dereference(local->service);
if (service_id == rx->srx.srx_service) if (rx && service_id == rx->srx.srx_service)
goto found_service; goto found_service;
trace_rxrpc_abort("INV", sp->hdr.cid, sp->hdr.callNumber, sp->hdr.seq, trace_rxrpc_abort("INV", sp->hdr.cid, sp->hdr.callNumber, sp->hdr.seq,
......
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