mirror of
https://github.com/ZDoom/raze-gles.git
synced 2024-12-25 03:00:46 +00:00
sdlmusic.c: disable FORK_EXEC_MIDI.
Also, if it were to be reenabled again, use execv() instead of execvp(), i.e. don't look up $PATH for the executable. git-svn-id: https://svn.eduke32.com/eduke32@4167 1a8010ca-5511-0410-912e-c29ae57300e0
This commit is contained in:
parent
863aae3fb1
commit
2972155f14
1 changed files with 12 additions and 12 deletions
|
@ -43,7 +43,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
|||
#include "music.h"
|
||||
|
||||
#if !defined _WIN32 && !defined(GEKKO)
|
||||
# define FORK_EXEC_MIDI 1
|
||||
//# define FORK_EXEC_MIDI 1
|
||||
#endif
|
||||
|
||||
#if defined FORK_EXEC_MIDI // fork/exec based external midi player
|
||||
|
@ -216,7 +216,7 @@ int32_t MUSIC_Init(int32_t SoundCard, int32_t Address)
|
|||
perror("MUSIC_Init: mprotect");
|
||||
goto fallback;
|
||||
}
|
||||
/*
|
||||
# if 0
|
||||
{
|
||||
int i;
|
||||
initprintf("----Music argv:\n");
|
||||
|
@ -224,7 +224,7 @@ int32_t MUSIC_Init(int32_t SoundCard, int32_t Address)
|
|||
initprintf(" %s\n", external_midi_argv[i]);
|
||||
initprintf("----\n");
|
||||
}
|
||||
*/
|
||||
# endif
|
||||
#endif
|
||||
music_initialized = 1;
|
||||
return(MUSIC_Ok);
|
||||
|
@ -406,8 +406,8 @@ static void playmusic()
|
|||
}
|
||||
else if (pid==0) // child
|
||||
{
|
||||
// exec with PATH lookup
|
||||
if (execvp(external_midi_argv[0], external_midi_argv) < 0)
|
||||
// exec without PATH lookup
|
||||
if (execv(external_midi_argv[0], external_midi_argv) < 0)
|
||||
{
|
||||
perror("execv");
|
||||
_exit(1);
|
||||
|
|
Loading…
Reference in a new issue