ALSA: hdsp: fix memory leak
PATCH 1/1 ALSA: hdsp: fix memory leak
If the size of the firmware is less than expected size then we are exiting with the error code but we missed releasing the firmware.
Signed-off-by Sudip Mukherjee <[email protected]>
--- sound/pci/rme9652/hdsp.c | 1 + 1 file changed, 1 insertion(+)
sound/pci/rme9652/hdsp.c +1 -0
@@ -5112,6 +5112,7 @@ static int hdsp_request_fw_loader(struct hdsp *hdsp)dev_err (hdsp->card->dev,"too short firmware size %d (expected %d)\n" , (int )fw->size,HDSP_FIRMWARE_SIZE ); +release_firmware (fw);return -EINVAL ; }
Signature · 1 line
1.9.1
Takashi Iwai
AppliedQuoted 5 lines · Sudip Mukherjee
If the size of the firmware is less than expected size then we are exiting with the error code but we missed releasing the firmware.
Signed-off-by Sudip Mukherjee <[email protected]>
Applied, thanks.
Takashi
Quoted 20 lines
--- sound/pci/rme9652/hdsp.c | 1 + 1 file changed, 1 insertion(+)sound/pci/rme9652/hdsp.c +1
-0@@ -5112,6 +5112,7 @@ static int hdsp_request_fw_loader(struct hdsp *hdsp)dev_err (hdsp->card->dev,"too short firmware size %d (expected %d)\n" , (int )fw->size,HDSP_FIRMWARE_SIZE ); +release_firmware (fw);return -EINVAL ; }Signature · 1 line
1.9.1