video: pvrusb2-hdw kfree cleanup
PATCH 1/1 video: pvrusb2-hdw kfree cleanup
Hello,
This patch removes redundant argument check for kfree().
drivers/media/video/pvrusb2/pvrusb2-hdw.c | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-)
drivers/media/video/pvrusb2/pvrusb2-hdw.c +8 -8
@@ -1926,10 +1926,10 @@ struct pvr2_hdw *pvr2_hdw_create(structif (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); }
Signature · 3 lines
Regards, Mariusz Kozlowski
Hello,
Quoted 4 lines
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 <[email protected]>
Signature · 3 lines
Regards, Mariusz Kozlowski
Quoted 10 lines · Mariusz Kozlowski
Hello,
Quoted 4 lines
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 <[email protected]>
Signed-off-by Mike Isely <[email protected]>
-Mike
Signature · 4 lines
| 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
| |