From 44f71cef92eb65bc4382ef3fb04a8e1437bda2d7 Mon Sep 17 00:00:00 2001 From: Fabian Frederick Date: Tue, 17 Jun 2014 21:22:50 +0200 Subject: [PATCH] drivers/net/irda/kingsun-sir.c: remove null test before kfree Fix checkpatch warning: WARNING: kfree(NULL) is safe this check is probably not required Cc: Samuel Ortiz Cc: netdev@vger.kernel.org Signed-off-by: Fabian Frederick Signed-off-by: David S. Miller --- drivers/net/irda/kingsun-sir.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/net/irda/kingsun-sir.c b/drivers/net/irda/kingsun-sir.c index 96fe3659012d..e638893e98a9 100644 --- a/drivers/net/irda/kingsun-sir.c +++ b/drivers/net/irda/kingsun-sir.c @@ -553,8 +553,8 @@ static int kingsun_probe(struct usb_interface *intf, return 0; free_mem: - if (kingsun->out_buf) kfree(kingsun->out_buf); - if (kingsun->in_buf) kfree(kingsun->in_buf); + kfree(kingsun->out_buf); + kfree(kingsun->in_buf); free_netdev(net); err_out1: return ret; -- 2.34.1