From 8c52d43306769706fd074bb776ed6a793b873ab4 Mon Sep 17 00:00:00 2001 From: Chris Danford Date: Tue, 3 Mar 2009 09:02:01 +0000 Subject: [PATCH] nondeterministic global ctor ordering might init this before SpecialFiles::NOTESKINS_DIR --- stepmania/src/NoteSkinManager.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/stepmania/src/NoteSkinManager.cpp b/stepmania/src/NoteSkinManager.cpp index f4b1752bfb..506d2aa97c 100644 --- a/stepmania/src/NoteSkinManager.cpp +++ b/stepmania/src/NoteSkinManager.cpp @@ -22,7 +22,10 @@ NoteSkinManager* NOTESKIN = NULL; // global object accessable from anywhere in t const RString GAME_COMMON_NOTESKIN_NAME = "common"; const RString GAME_BASE_NOTESKIN_NAME = "default"; -const RString GLOBAL_BASE_DIR = SpecialFiles::NOTESKINS_DIR + GAME_COMMON_NOTESKIN_NAME + "/"; + +// this isn't a global because of nondeterministic global ctor ordering might init this before SpecialFiles::NOTESKINS_DIR +#define GLOBAL_BASE_DIR (SpecialFiles::NOTESKINS_DIR + GAME_COMMON_NOTESKIN_NAME + "/") + static map g_PathCache; struct NoteSkinData