]> git.proxmox.com Git - mirror_ubuntu-focal-kernel.git/commit
media: usbtv: Fix refcounting mixup
authorOliver Neukum <oneukum@suse.com>
Thu, 24 Sep 2020 09:14:10 +0000 (11:14 +0200)
committerStefan Bader <stefan.bader@canonical.com>
Mon, 9 Nov 2020 13:48:27 +0000 (14:48 +0100)
commite0354ab3206102c676ccfbb5f451d2a119ea98fc
tree23893403c5fec331767acecd7608cf122c1da50f
parente2e86655d56a8928ee4e37b1a9616fcd895c1fa3
media: usbtv: Fix refcounting mixup

BugLink: https://bugs.launchpad.net/bugs/1902111
commit bf65f8aabdb37bc1a785884374e919477fe13e10 upstream.

The premature free in the error path is blocked by V4L
refcounting, not USB refcounting. Thanks to
Ben Hutchings for review.

[v2] corrected attributions

Signed-off-by: Oliver Neukum <oneukum@suse.com>
Fixes: 50e704453553 ("media: usbtv: prevent double free in error case")
CC: stable@vger.kernel.org
Reported-by: Ben Hutchings <ben.hutchings@codethink.co.uk>
Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Kamal Mostafa <kamal@canonical.com>
Signed-off-by: Ian May <ian.may@canonical.com>
drivers/media/usb/usbtv/usbtv-core.c