* [patch] rtc: use after free in pcf50633_rtc_probe()
@ 2009-11-18 8:30 Dan Carpenter
2009-11-18 10:06 ` [rtc-linux] " Alessandro Zummo
0 siblings, 1 reply; 2+ messages in thread
From: Dan Carpenter @ 2009-11-18 8:30 UTC (permalink / raw)
To: balajirrao; +Cc: rtc-linux, linux-kernel
"rtc" is freed and then dereferenced on the next line. This patch fixes
that.
This is a resend. I have been offline for the last few months so I may
have missed a reply or something. Not sure what the status was.
regards,
dan carpenter
Signed-off-by: Dan Carpenter <error27@gmail.com>
--- orig/drivers/rtc/rtc-pcf50633.c 2009-07-17 16:21:52.000000000 +0300
+++ new/drivers/rtc/rtc-pcf50633.c 2009-07-17 16:22:56.000000000 +0300
@@ -291,8 +291,9 @@
&pcf50633_rtc_ops, THIS_MODULE);
if (IS_ERR(rtc->rtc_dev)) {
+ int ret = PTR_ERR(rtc->rtc_dev);
kfree(rtc);
- return PTR_ERR(rtc->rtc_dev);
+ return ret;
}
pcf50633_register_irq(rtc->pcf, PCF50633_IRQ_ALARM,
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [rtc-linux] [patch] rtc: use after free in pcf50633_rtc_probe()
2009-11-18 8:30 [patch] rtc: use after free in pcf50633_rtc_probe() Dan Carpenter
@ 2009-11-18 10:06 ` Alessandro Zummo
0 siblings, 0 replies; 2+ messages in thread
From: Alessandro Zummo @ 2009-11-18 10:06 UTC (permalink / raw)
To: rtc-linux; +Cc: error27, balajirrao, linux-kernel, akpm
On Wed, 18 Nov 2009 10:30:14 +0200 (SAST)
Dan Carpenter <error27@gmail.com> wrote:
> "rtc" is freed and then dereferenced on the next line. This patch fixes
> that.
>
> This is a resend. I have been offline for the last few months so I may
> have missed a reply or something. Not sure what the status was.
>
> regards,
> dan carpenter
>
> Signed-off-by: Dan Carpenter <error27@gmail.com>
Acked-by: Alessandro Zummo <a.zummo@towertech.it>
--
Best regards,
Alessandro Zummo,
Tower Technologies - Torino, Italy
http://www.towertech.it
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2009-11-18 10:13 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-11-18 8:30 [patch] rtc: use after free in pcf50633_rtc_probe() Dan Carpenter
2009-11-18 10:06 ` [rtc-linux] " Alessandro Zummo
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox