diff options
author | Max Kellermann <max@duempel.org> | 2008-08-26 08:27:15 +0200 |
---|---|---|
committer | Max Kellermann <max@duempel.org> | 2008-08-26 08:27:15 +0200 |
commit | edd7e2f94e8f9ca5340ab1c6392417c7e85b3aa9 (patch) | |
tree | c19f3140b6874350fb35af67cac0917df6ddd72d /src/audioOutputs/audioOutput_jack.c | |
parent | 806a9f02a10310be5aa8fba16ae87a647b28952a (diff) | |
download | mpd-edd7e2f94e8f9ca5340ab1c6392417c7e85b3aa9.tar.gz mpd-edd7e2f94e8f9ca5340ab1c6392417c7e85b3aa9.tar.xz mpd-edd7e2f94e8f9ca5340ab1c6392417c7e85b3aa9.zip |
jack: don't set audioOutput->data=NULL
There is only one caller of freeJackData() left: jack_finishDriver().
This function is called by the mpd core, and is called exactly once
for every successful jack_initDriver(). We do not need to clear
audioOutput->data, since this variable is invalidated anyway.
Diffstat (limited to 'src/audioOutputs/audioOutput_jack.c')
-rw-r--r-- | src/audioOutputs/audioOutput_jack.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/audioOutputs/audioOutput_jack.c b/src/audioOutputs/audioOutput_jack.c index 9fc52055f..5e0b1b599 100644 --- a/src/audioOutputs/audioOutput_jack.c +++ b/src/audioOutputs/audioOutput_jack.c @@ -87,11 +87,11 @@ static void freeJackClient(JackData *jd) static void freeJackData(AudioOutput *audioOutput) { JackData *jd = audioOutput->data; - if (jd) { - freeJackClient(jd); - free(jd); - audioOutput->data = NULL; - } + + assert(jd != NULL); + + freeJackClient(jd); + free(jd); } static void jack_finishDriver(AudioOutput *audioOutput) |