* [PATCH] video: pvrusb2-hdw kfree cleanup
@ 2007-01-02 11:44 Mariusz Kozlowski
2007-01-02 12:26 ` Mariusz Kozlowski
0 siblings, 1 reply; 3+ messages in thread
From: Mariusz Kozlowski @ 2007-01-02 11:44 UTC (permalink / raw)
To: isely; +Cc: pvrusb2, video4linux-list, linux-kernel
Hello,
This patch removes redundant argument check for kfree().
drivers/media/video/pvrusb2/pvrusb2-hdw.c | 16 ++++++++--------
1 file changed, 8 insertions(+), 8 deletions(-)
diff -upr linux-2.6.20-rc2-mm1-a/drivers/media/video/pvrusb2/pvrusb2-hdw.c linux-2.6.20-rc2-mm1-b/drivers/media/video/pvrusb2/pvrusb2-hdw.c
--- linux-2.6.20-rc2-mm1-a/drivers/media/video/pvrusb2/pvrusb2-hdw.c 2006-12-28 12:57:37.000000000 +0100
+++ linux-2.6.20-rc2-mm1-b/drivers/media/video/pvrusb2/pvrusb2-hdw.c 2007-01-02 01:48:31.000000000 +0100
@@ -1926,10 +1926,10 @@ struct pvr2_hdw *pvr2_hdw_create(struct
if (hdw) {
usb_free_urb(hdw->ctl_read_urb);
usb_free_urb(hdw->ctl_write_urb);
- if (hdw->ctl_read_buffer) kfree(hdw->ctl_read_buffer);
- if (hdw->ctl_write_buffer) kfree(hdw->ctl_write_buffer);
- if (hdw->controls) kfree(hdw->controls);
- if (hdw->mpeg_ctrl_info) kfree(hdw->mpeg_ctrl_info);
+ kfree(hdw->ctl_read_buffer);
+ kfree(hdw->ctl_write_buffer);
+ kfree(hdw->controls);
+ kfree(hdw->mpeg_ctrl_info);
kfree(hdw);
}
return NULL;
@@ -1994,10 +1994,10 @@ void pvr2_hdw_destroy(struct pvr2_hdw *h
unit_pointers[hdw->unit_number] = NULL;
}
} while (0); up(&pvr2_unit_sem);
- if (hdw->controls) kfree(hdw->controls);
- if (hdw->mpeg_ctrl_info) kfree(hdw->mpeg_ctrl_info);
- if (hdw->std_defs) kfree(hdw->std_defs);
- if (hdw->std_enum_names) kfree(hdw->std_enum_names);
+ kfree(hdw->controls);
+ kfree(hdw->mpeg_ctrl_info);
+ kfree(hdw->std_defs);
+ kfree(hdw->std_enum_names);
kfree(hdw);
}
--
Regards,
Mariusz Kozlowski
^ permalink raw reply [flat|nested] 3+ messages in thread* Re: [PATCH] video: pvrusb2-hdw kfree cleanup
2007-01-02 11:44 [PATCH] video: pvrusb2-hdw kfree cleanup Mariusz Kozlowski
@ 2007-01-02 12:26 ` Mariusz Kozlowski
2007-01-03 2:57 ` Mike Isely
0 siblings, 1 reply; 3+ messages in thread
From: Mariusz Kozlowski @ 2007-01-02 12:26 UTC (permalink / raw)
To: isely; +Cc: pvrusb2, video4linux-list, linux-kernel
Hello,
> This patch removes redundant argument check for kfree().
>
> drivers/media/video/pvrusb2/pvrusb2-hdw.c | 16 ++++++++--------
> 1 file changed, 8 insertions(+), 8 deletions(-)
Signed-off-by: Mariusz Kozlowski <m.kozlowski@tuxland.pl>
--
Regards,
Mariusz Kozlowski
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] video: pvrusb2-hdw kfree cleanup
2007-01-02 12:26 ` Mariusz Kozlowski
@ 2007-01-03 2:57 ` Mike Isely
0 siblings, 0 replies; 3+ messages in thread
From: Mike Isely @ 2007-01-03 2:57 UTC (permalink / raw)
To: Mariusz Kozlowski
Cc: video4linux-list, Linux Kernel Mailing List, Mike Isely at pobox
On Tue, 2 Jan 2007, Mariusz Kozlowski wrote:
> Hello,
>
> > This patch removes redundant argument check for kfree().
> >
> > drivers/media/video/pvrusb2/pvrusb2-hdw.c | 16 ++++++++--------
> > 1 file changed, 8 insertions(+), 8 deletions(-)
>
> Signed-off-by: Mariusz Kozlowski <m.kozlowski@tuxland.pl>
>
>
Signed-off-by: Mike Isely <isely@pobox.com>
-Mike
--
| Mike Isely | PGP fingerprint
Spammers Die!! | | 03 54 43 4D 75 E5 CC 92
| isely @ pobox (dot) com | 71 16 01 E2 B5 F5 C1 E8
| |
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2007-01-03 3:02 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2007-01-02 11:44 [PATCH] video: pvrusb2-hdw kfree cleanup Mariusz Kozlowski
2007-01-02 12:26 ` Mariusz Kozlowski
2007-01-03 2:57 ` Mike Isely
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®