Skip to content

Commit

Permalink
ASoC: sst_platform: free the resources on fail path
Browse files Browse the repository at this point in the history
Signed-off-by: Lu Guanqun <guanqun.lu@intel.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
  • Loading branch information
Lu Guanqun authored and Mark Brown committed Apr 6, 2011
1 parent 0d1d7ce commit 83a3fd3
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions sound/soc/mid-x86/sst_platform.c
Original file line number Diff line number Diff line change
Expand Up @@ -252,6 +252,8 @@ static int sst_platform_open(struct snd_pcm_substream *substream)
ret_val = register_sst_card(stream->sstdrv_ops);
if (ret_val) {
pr_err("sst: sst card registration failed\n");
kfree(stream->sstdrv_ops);
kfree(stream);
return ret_val;
}
runtime->private_data = stream;
Expand Down

0 comments on commit 83a3fd3

Please sign in to comment.