[PATCH] staging: bcm2835-audio: Fix memory corruption

Dan Carpenter dan.carpenter at oracle.com
Thu Aug 10 04:05:53 PDT 2017


On Thu, Aug 10, 2017 at 11:52:42AM +0100, Phil Elwell wrote:
> > This label name is out of date.  There is a later error path where
> > vc_vchi_audio_init() fails and we leak on that path.
> 
> Also agreed. I'll rework it.
> 

Actually I wasn't right.  That error path should probably stay how it
is, because we're re-using the vchi_instance.  We allocate it in the
first call then re-use it later.

This code is really subtle and ugly.

regards,
dan carpenter




More information about the linux-rpi-kernel mailing list