This is an automatic generated email to let you know that the following patch were queued:
Subject: media: dvbdev: drop refcount on error path in dvb_device_open() Author: Dan Carpenter <dan.carpen...@linaro.org> Date: Tue Oct 31 12:53:33 2023 +0300 If call to file->f_op->open() fails, then call dvb_device_put(dvbdev). Fixes: 0fc044b2b5e2 ("media: dvbdev: adopts refcnt to avoid UAF") Signed-off-by: Dan Carpenter <dan.carpen...@linaro.org> Signed-off-by: Hans Verkuil <hverkuil-ci...@xs4all.nl> drivers/media/dvb-core/dvbdev.c | 2 ++ 1 file changed, 2 insertions(+) --- diff --git a/drivers/media/dvb-core/dvbdev.c b/drivers/media/dvb-core/dvbdev.c index 305bb21d843c..49f0eb7d0b9d 100644 --- a/drivers/media/dvb-core/dvbdev.c +++ b/drivers/media/dvb-core/dvbdev.c @@ -104,6 +104,8 @@ static int dvb_device_open(struct inode *inode, struct file *file) err = file->f_op->open(inode, file); up_read(&minor_rwsem); mutex_unlock(&dvbdev_mutex); + if (err) + dvb_device_put(dvbdev); return err; } fail: _______________________________________________ linuxtv-commits mailing list linuxtv-commits@linuxtv.org https://www.linuxtv.org/cgi-bin/mailman/listinfo/linuxtv-commits