Commit 8d8e9054 authored by Felix Paul Kühne's avatar Felix Paul Kühne

playback: protect [VLCMediaPlayer stop] (refs #9393)

parent 62f20b24
...@@ -472,9 +472,14 @@ ...@@ -472,9 +472,14 @@
APLog(@"we weren't an observer yet"); APLog(@"we weren't an observer yet");
} }
[_mediaPlayer pause]; if (_mediaPlayer.media) {
[self _saveCurrentState]; NSInteger state = _mediaPlayer.state;
[_mediaPlayer stop]; if (state != VLCMediaPlayerStateStopped && state != VLCMediaPlayerStateEnded && state != VLCMediaPlayerStateError) {
[_mediaPlayer pause];
[self _saveCurrentState];
[_mediaPlayer stop];
}
}
} }
if (_mediaItem) if (_mediaItem)
_mediaItem = nil; _mediaItem = nil;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment