Skip to content

Commit

Permalink
ALSA: sgio2audio.c: clean up checking
Browse files Browse the repository at this point in the history
vfree() does it's own 'NULL' check,so no need for check before
calling it.

Signed-off-by: Figo.zhang <[email protected]>
Signed-off-by: Takashi Iwai <[email protected]>
  • Loading branch information
Figo1802 authored and tiwai committed Jun 7, 2009
1 parent 13be1bf commit ad0b082
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions sound/mips/sgio2audio.c
Original file line number Diff line number Diff line change
Expand Up @@ -619,8 +619,7 @@ static int snd_sgio2audio_pcm_hw_params(struct snd_pcm_substream *substream,
/* hw_free callback */
static int snd_sgio2audio_pcm_hw_free(struct snd_pcm_substream *substream)
{
if (substream->runtime->dma_area)
vfree(substream->runtime->dma_area);
vfree(substream->runtime->dma_area);
substream->runtime->dma_area = NULL;
return 0;
}
Expand Down

0 comments on commit ad0b082

Please sign in to comment.