Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Skip to content
Commit 5e85bd05 authored by Trent Piepho's avatar Trent Piepho Committed by Mauro Carvalho Chehab
Browse files

V4L/DVB (3672): Fix memory leak in dvr open



The dvr device could be opened multiple times simultaneously in O_RDONLY mode.
Each open after the first would allocate a new dvr buffer (1880 KB) and leak
the old buffer.  The first close would de-allocate the dvr buffer and cause
all other open dvrs to stop working.  This patch allows only a single O_RDONLY
open of the drv device, as per the API specification.  Multiple O_WRONLY opens
are still allowed and don't appear to cause any problems.

Signed-off-by: default avatarTrent Piepho <xyzzy@speakeasy.org>
Signed-off-by: default avatarAndrew de Quincey <adq_dvb@lidskialf.net>
Signed-off-by: default avatarMauro Carvalho Chehab <mchehab@infradead.org>
parent 2f03ee8e
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment