diff -Naur xu4-1.2.1/src/settings.cpp xu4-1.2.1.patched/src/settings.cpp --- xu4-1.2.1/src/settings.cpp 2022-12-06 13:21:00.000000000 -0500 +++ xu4-1.2.1.patched/src/settings.cpp 2023-01-13 03:37:36.452626171 -0500 @@ -55,15 +55,6 @@ * Initialize the settings. */ void Settings::init(const char* profileName) { - if (profileName && profileName[0]) { - userPath = "./profiles/"; - userPath += profileName; - userPath += "/"; - - profile = profileName; - if (profile.length() > 20) - errorFatal("Profile name must be no more than 20 characters."); - } else { profile.clear(); #if defined(ANDROID) @@ -123,6 +114,14 @@ userPath = "./"; #endif + if (profileName && profileName[0]) { + userPath += "profiles/"; + userPath += profileName; + userPath += "/"; + + profile = profileName; + if (profile.length() > 20) + errorFatal("Profile name must be no more than 20 characters."); } #ifndef ANDROID