aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSachin Kamat <sachin.kamat@linaro.org>2012-11-21 04:06:54 -0500
committerTakashi Iwai <tiwai@suse.de>2012-11-21 04:43:26 -0500
commit51d503de0210a2b800efdedee23580011f5422c3 (patch)
treedee76703aaedec8a78d4966541edf35a359331c9
parent87af0b80c933f05a4c7dd8c5edebe10365e76220 (diff)
ALSA: PCM: Remove redundant null check before kfree
kfree on a null pointer is a no-op. Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org> Signed-off-by: Takashi Iwai <tiwai@suse.de>
-rw-r--r--sound/core/pcm.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/sound/core/pcm.c b/sound/core/pcm.c
index 030102caeee9..61798f85d030 100644
--- a/sound/core/pcm.c
+++ b/sound/core/pcm.c
@@ -981,8 +981,7 @@ void snd_pcm_detach_substream(struct snd_pcm_substream *substream)
981 PAGE_ALIGN(sizeof(struct snd_pcm_mmap_control))); 981 PAGE_ALIGN(sizeof(struct snd_pcm_mmap_control)));
982 kfree(runtime->hw_constraints.rules); 982 kfree(runtime->hw_constraints.rules);
983#ifdef CONFIG_SND_PCM_XRUN_DEBUG 983#ifdef CONFIG_SND_PCM_XRUN_DEBUG
984 if (runtime->hwptr_log) 984 kfree(runtime->hwptr_log);
985 kfree(runtime->hwptr_log);
986#endif 985#endif
987 kfree(runtime); 986 kfree(runtime);
988 substream->runtime = NULL; 987 substream->runtime = NULL;