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

Commit 3251627c authored by Dan Carpenter's avatar Dan Carpenter Committed by Greg Kroah-Hartman
Browse files

Staging: intel_sst: fix memory leak



The original code set "str_info->decode_ibuf" to NULL so the kfree() is
no-op.

Signed-off-by: default avatarDan Carpenter <error27@gmail.com>
Acked-by: default avatarHarsha Priya <priya.harsha@intel.com>
Acked-by: default avatarAlan Cox <alan@linux.intel.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
parent 83285535
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -1269,7 +1269,7 @@ int sst_decode(int str_id, struct snd_sst_dbufs *dbufs)
	dbufs->output_bytes_produced = total_output;
	str_info->status = str_info->prev;
	str_info->prev = STREAM_DECODE;
	str_info->decode_ibuf = NULL;
	kfree(str_info->decode_ibuf);
	str_info->decode_ibuf = NULL;
	return retval;
}