linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH][net-next] rxrpc: remove redundant proc_remove call
@ 2017-06-02 15:22 Colin King
  2017-06-02 21:37 ` David Howells
  2017-06-04 23:59 ` David Miller
  0 siblings, 2 replies; 3+ messages in thread
From: Colin King @ 2017-06-02 15:22 UTC (permalink / raw)
  To: David S . Miller, David Howells, netdev; +Cc: kernel-janitors, linux-kernel

From: Colin Ian King <colin.king@canonical.com>

The proc_remove call is dead code as it occurs after a return and
hence can never be called. Remove it.

Detected by CoverityScan, CID#1437743 ("Logically dead code")

Signed-off-by: Colin Ian King <colin.king@canonical.com>
---
 net/rxrpc/net_ns.c | 1 -
 1 file changed, 1 deletion(-)

diff --git a/net/rxrpc/net_ns.c b/net/rxrpc/net_ns.c
index 26449a6bb076..7edceb8522f5 100644
--- a/net/rxrpc/net_ns.c
+++ b/net/rxrpc/net_ns.c
@@ -59,7 +59,6 @@ static __net_init int rxrpc_init_net(struct net *net)
 	proc_create("conns", 0444, rxnet->proc_net, &rxrpc_connection_seq_fops);
 	return 0;
 
-	proc_remove(rxnet->proc_net);
 err_proc:
 	return ret;
 }
-- 
2.11.0

^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH][net-next] rxrpc: remove redundant proc_remove call
  2017-06-02 15:22 [PATCH][net-next] rxrpc: remove redundant proc_remove call Colin King
@ 2017-06-02 21:37 ` David Howells
  2017-06-04 23:59 ` David Miller
  1 sibling, 0 replies; 3+ messages in thread
From: David Howells @ 2017-06-02 21:37 UTC (permalink / raw)
  To: Colin King
  Cc: dhowells, David S . Miller, netdev, kernel-janitors, linux-kernel

Colin King <colin.king@canonical.com> wrote:

> From: Colin Ian King <colin.king@canonical.com>
> 
> The proc_remove call is dead code as it occurs after a return and
> hence can never be called. Remove it.
> 
> Detected by CoverityScan, CID#1437743 ("Logically dead code")
> 
> Signed-off-by: Colin Ian King <colin.king@canonical.com>

Acked-by: David Howells <dhowells@redhat.com>

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH][net-next] rxrpc: remove redundant proc_remove call
  2017-06-02 15:22 [PATCH][net-next] rxrpc: remove redundant proc_remove call Colin King
  2017-06-02 21:37 ` David Howells
@ 2017-06-04 23:59 ` David Miller
  1 sibling, 0 replies; 3+ messages in thread
From: David Miller @ 2017-06-04 23:59 UTC (permalink / raw)
  To: colin.king; +Cc: dhowells, netdev, kernel-janitors, linux-kernel

From: Colin King <colin.king@canonical.com>
Date: Fri,  2 Jun 2017 16:22:27 +0100

> From: Colin Ian King <colin.king@canonical.com>
> 
> The proc_remove call is dead code as it occurs after a return and
> hence can never be called. Remove it.
> 
> Detected by CoverityScan, CID#1437743 ("Logically dead code")
> 
> Signed-off-by: Colin Ian King <colin.king@canonical.com>

Applied.

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2017-06-04 23:59 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-06-02 15:22 [PATCH][net-next] rxrpc: remove redundant proc_remove call Colin King
2017-06-02 21:37 ` David Howells
2017-06-04 23:59 ` David Miller

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).