From 16c61add51f2182140637c924687a2aab6b568f9 Mon Sep 17 00:00:00 2001 From: Adrian Bunk Date: Fri, 15 Jun 2007 15:15:43 -0700 Subject: [PATCH] [RXRPC] net/rxrpc/ar-connection.c: fix NULL dereference This patch fixes a NULL dereference spotted by the Coverity checker. Signed-off-by: Adrian Bunk Signed-off-by: David S. Miller --- net/rxrpc/ar-connection.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/net/rxrpc/ar-connection.c b/net/rxrpc/ar-connection.c index 43cb3e0..482750e 100644 --- a/net/rxrpc/ar-connection.c +++ b/net/rxrpc/ar-connection.c @@ -211,7 +211,7 @@ static struct rxrpc_connection *rxrpc_alloc_connection(gfp_t gfp) conn->header_size = sizeof(struct rxrpc_header); } - _leave(" = %p{%d}", conn, conn->debug_id); + _leave(" = %p{%d}", conn, conn ? conn->debug_id : 0); return conn; } -- 2.7.4