]> git.ipfire.org Git - thirdparty/linux.git/commit
media: pci: zoran: fix potential memory leak in zoran_probe()
authorAbdun Nihaal <nihaal@cse.iitm.ac.in>
Thu, 12 Mar 2026 12:32:56 +0000 (18:02 +0530)
committerHans Verkuil <hverkuil+cisco@kernel.org>
Mon, 16 Mar 2026 15:30:21 +0000 (16:30 +0100)
commit8ea21435fe36fb853706f4935d78bc11beb63fb4
tree664009e273415d63d1aecb47a4152b6200ff4aff
parenta66485a934c7187ae8e36517d40615fa2e961cff
media: pci: zoran: fix potential memory leak in zoran_probe()

The memory allocated for codec in videocodec_attach() is not freed in
one of the error paths, due to an incorrect goto label. Fix the label
to free it on error.

Fixes: 8f7cc5c0b0eb ("media: staging: media: zoran: introduce zoran_i2c_init")
Cc: stable@vger.kernel.org
Signed-off-by: Abdun Nihaal <nihaal@cse.iitm.ac.in>
Signed-off-by: Hans Verkuil <hverkuil+cisco@kernel.org>
drivers/media/pci/zoran/zoran_card.c