Commit ac56886
media: em28xx: Fix possible memory leak of em28xx struct
The em28xx struct kref isn't being decreased after an error in the
em28xx_ir_init, leading to a possible memory leak.
A kref_put and em28xx_shutdown_buttons is added to the error handler code.
Signed-off-by: Igor Matheus Andrade Torrente <igormtorrente@gmail.com>
Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>1 parent a3a54bf commit ac56886
1 file changed
+6
-2
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
720 | 720 | | |
721 | 721 | | |
722 | 722 | | |
723 | | - | |
| 723 | + | |
| 724 | + | |
724 | 725 | | |
725 | 726 | | |
726 | 727 | | |
| |||
735 | 736 | | |
736 | 737 | | |
737 | 738 | | |
738 | | - | |
| 739 | + | |
739 | 740 | | |
740 | 741 | | |
741 | 742 | | |
| |||
839 | 840 | | |
840 | 841 | | |
841 | 842 | | |
| 843 | + | |
| 844 | + | |
| 845 | + | |
842 | 846 | | |
843 | 847 | | |
844 | 848 | | |
| |||
0 commit comments