[PATCH] ALSA: ac97: fix possible memory leak in snd_ac97_dev_register()

Takashi Iwai tiwai at suse.de
Thu Oct 20 14:20:09 CEST 2022


On Wed, 19 Oct 2022 11:30:25 +0200,
Yang Yingliang wrote:
> 
> If device_register() fails in snd_ac97_dev_register(), it should
> call put_device() to give up reference, or the name allocated in
> dev_set_name() is leaked.
> 
> Fixes: 0ca06a00e206 ("[ALSA] AC97 bus interface for ad-hoc drivers")
> Signed-off-by: Yang Yingliang <yangyingliang at huawei.com>

Thanks, applied.


Takashi


More information about the Alsa-devel mailing list