aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/media/usb/tm6000/tm6000-video.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/media/usb/tm6000/tm6000-video.c')
-rw-r--r--drivers/media/usb/tm6000/tm6000-video.c9
1 files changed, 4 insertions, 5 deletions
diff --git a/drivers/media/usb/tm6000/tm6000-video.c b/drivers/media/usb/tm6000/tm6000-video.c
index d9f3fa5db8dd..c4fdc1fa32ef 100644
--- a/drivers/media/usb/tm6000/tm6000-video.c
+++ b/drivers/media/usb/tm6000/tm6000-video.c
@@ -14,10 +14,6 @@
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
*/
#include <linux/module.h>
@@ -1375,8 +1371,11 @@ static int __tm6000_open(struct file *file)
/* initialize hardware on analog mode */
rc = tm6000_init_analog_mode(dev);
- if (rc < 0)
+ if (rc < 0) {
+ v4l2_fh_exit(&fh->fh);
+ kfree(fh);
return rc;
+ }
dev->mode = TM6000_MODE_ANALOG;