rtc/m48t59: redundant condition judgement

Submitted by Wan ZongShun on June 4, 2010, 8:42 a.m.

Details

Message ID 4C08BC8C.4010206@gmail.com
State Accepted
Headers show

Commit Message

Wan ZongShun June 4, 2010, 8:42 a.m.
It is safe to deallocate a NULL pointer.
so 'if (m48t59)' is redundant condition judgement,
so I remove it.

Signed-off-by: Wan ZongShun <mcuos.com@gmail.com>

---
 drivers/rtc/rtc-m48t59.c |    1 -
 1 files changed, 0 insertions(+), 1 deletions(-)

Patch hide | download patch | download mbox

diff --git a/drivers/rtc/rtc-m48t59.c b/drivers/rtc/rtc-m48t59.c
index be8359f..0b66455 100644
--- a/drivers/rtc/rtc-m48t59.c
+++ b/drivers/rtc/rtc-m48t59.c
@@ -506,7 +506,6 @@  out:
 		free_irq(m48t59->irq, &pdev->dev);
 	if (m48t59->ioaddr)
 		iounmap(m48t59->ioaddr);
-	if (m48t59)
 		kfree(m48t59);
 	return ret;
 }