Rather than pretending that our UserMusicPath isn't hardcoded, lets just admit it and make it a `static const char`

git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@4576 4a71c877-e1ca-e34f-864e-861f7616d084
master
Giel van Schijndel 2008-04-12 21:31:29 +00:00
parent f030d2944b
commit 85d51e6a32
3 changed files with 3 additions and 6 deletions

View File

@ -41,9 +41,8 @@ BOOL cdAudio_Open(const char* user_musicdir)
{
PlayList_Init();
if ((user_musicdir == NULL
if (user_musicdir == NULL
|| !PlayList_Read(user_musicdir))
&& !PlayList_Read("music"))
{
return false;
}

View File

@ -95,7 +95,7 @@
static void initMiscVars(void);
extern char UserMusicPath[];
static const char UserMusicPath[] = "music";
extern char * global_mods[];
extern char * campaign_mods[];

View File

@ -135,7 +135,6 @@ char MultiForcesPath[PATH_MAX];
char MultiCustomMapsPath[PATH_MAX];
char MultiPlayersPath[PATH_MAX];
char KeyMapPath[PATH_MAX];
char UserMusicPath[PATH_MAX];
// Start game in title mode:
static GS_GAMEMODE gameStatus = GS_TITLE_SCREEN;
@ -888,7 +887,6 @@ int main(int argc, char *argv[])
/* Put these files in the writedir root */
setRegistryFilePath("config");
strlcpy(KeyMapPath, "keymap.map", sizeof(KeyMapPath));
strlcpy(UserMusicPath, "music", sizeof(UserMusicPath));
// initialise all the command line states
war_SetDefaultStates();