From d171fe9a2f016899f7a05916382e89fbb7c3869e Mon Sep 17 00:00:00 2001 From: Warren Dukes Date: Fri, 22 Oct 2004 15:19:35 +0000 Subject: fix segfault when resuming from pause git-svn-id: https://svn.musicpd.org/mpd/trunk@2293 09075e82-0dd4-0310-85a5-a0d7c8717e4f --- src/audio.c | 1 + 1 file changed, 1 insertion(+) (limited to 'src') diff --git a/src/audio.c b/src/audio.c index b897d8bc9..79645244d 100644 --- a/src/audio.c +++ b/src/audio.c @@ -150,6 +150,7 @@ int isCurrentAudioFormat(AudioFormat * audioFormat) { int openAudioDevice(AudioFormat * audioFormat) { if(!aoOutput->open || !isCurrentAudioFormat(audioFormat)) { + if(!audioFormat) return -1; copyAudioFormat(&audio_format, audioFormat); if(shoutOutput) openAudioOutput(shoutOutput, audioFormat); return openAudioOutput(aoOutput, audioFormat); -- cgit v1.2.3