aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--net/core/sock.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/net/core/sock.c b/net/core/sock.c
index 61a65a2e0455..c5812bbc2cc9 100644
--- a/net/core/sock.c
+++ b/net/core/sock.c
@@ -2288,7 +2288,8 @@ out_free_request_sock_slab:
2288 prot->rsk_prot->slab = NULL; 2288 prot->rsk_prot->slab = NULL;
2289 } 2289 }
2290out_free_request_sock_slab_name: 2290out_free_request_sock_slab_name:
2291 kfree(prot->rsk_prot->slab_name); 2291 if (prot->rsk_prot)
2292 kfree(prot->rsk_prot->slab_name);
2292out_free_sock_slab: 2293out_free_sock_slab:
2293 kmem_cache_destroy(prot->slab); 2294 kmem_cache_destroy(prot->slab);
2294 prot->slab = NULL; 2295 prot->slab = NULL;