summaryrefslogtreecommitdiffstats
path: root/fs/btrfs/locking.c
diff options
context:
space:
mode:
authorTakashi Iwai <tiwai@suse.de>2019-12-04 16:14:54 +0100
committerMark Brown <broonie@kernel.org>2019-12-24 23:56:15 +0000
commit07d22a9bb623714dc3199099c5cce3df6aef496c (patch)
tree91537a1b83a67aaa9fd3ff0709ebde701a60248b /fs/btrfs/locking.c
parent218fe9b7ec7f32c10a07539365488d80af7b0084 (diff)
downloadlinux-07d22a9bb623714dc3199099c5cce3df6aef496c.tar.bz2
ASoC: core: Fix access to uninitialized list heads
The error path of soc_new_pcm_runtime() invokes soc_free_pcm_runtime() that may cause a few problems. First off, it calls list_del() for rtd->list that may not be initialized. Similarly, snd_soc_pcm_component_free() traverses over the component list that may not be initialized, either. Such access to the uninitialized list head would lead to either a BUG_ON() or a memory corruption. This patch fixes the access to uninitialized list heads by initializing the list heads properly at the beginning before those error paths. Signed-off-by: Takashi Iwai <tiwai@suse.de> Reviewed-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Link: https://lore.kernel.org/r/20191204151454.21643-1-tiwai@suse.de Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'fs/btrfs/locking.c')
0 files changed, 0 insertions, 0 deletions