mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-08-27 11:19:37 +00:00
ALSA: hda - Fix memory leak at codec creation
The codec->modelname field is allocated twice in snd_hda_codec_new(). Signed-off-by: Takashi Iwai <tiwai@suse.de>
This commit is contained in:
parent
e46b0c8c08
commit
f75dcc87fe
1 changed files with 0 additions and 2 deletions
|
@ -972,8 +972,6 @@ int /*__devinit*/ snd_hda_codec_new(struct hda_bus *bus, unsigned int codec_addr
|
|||
snd_hda_codec_read(codec, nid, 0,
|
||||
AC_VERB_GET_SUBSYSTEM_ID, 0);
|
||||
}
|
||||
if (bus->modelname)
|
||||
codec->modelname = kstrdup(bus->modelname, GFP_KERNEL);
|
||||
|
||||
/* power-up all before initialization */
|
||||
hda_set_power_state(codec,
|
||||
|
|
Loading…
Reference in a new issue