mirror of
https://github.com/libretro/RetroArch.git
synced 2024-11-24 16:39:43 +00:00
(audio_mixer.c) Prevent null pointer dereference
This commit is contained in:
parent
5e7f175545
commit
5245590bae
@ -455,7 +455,8 @@ audio_mixer_voice_t* audio_mixer_play(audio_mixer_sound_t* sound, bool repeat,
|
||||
|
||||
void audio_mixer_stop(audio_mixer_voice_t* voice)
|
||||
{
|
||||
voice->stop_cb(voice, AUDIO_MIXER_SOUND_STOPPED);
|
||||
if (voice && voice->stop_cb)
|
||||
voice->stop_cb(voice, AUDIO_MIXER_SOUND_STOPPED);
|
||||
}
|
||||
|
||||
static void mix_wav(float* buffer, size_t num_frames, audio_mixer_voice_t* voice)
|
||||
|
@ -1051,10 +1051,10 @@ bool task_push_start_dummy_core(content_ctx_info_t *content_info)
|
||||
|
||||
/* Preliminary stuff that has to be done before we
|
||||
* load the actual content. Can differ per mode. */
|
||||
runloop_ctl(RUNLOOP_CTL_STATE_FREE, NULL);
|
||||
#ifdef HAVE_MENU
|
||||
menu_driver_ctl(RARCH_MENU_CTL_UNSET_LOAD_NO_CONTENT, NULL);
|
||||
#endif
|
||||
runloop_ctl(RUNLOOP_CTL_STATE_FREE, NULL);
|
||||
runloop_ctl(RUNLOOP_CTL_DATA_DEINIT, NULL);
|
||||
runloop_ctl(RUNLOOP_CTL_TASK_INIT, NULL);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user