mirror of
https://gitlab.com/pholy/OSCAR-code.git
synced 2025-04-05 10:40:42 +00:00
Allow a Windows path with drive letter to be used as an argument for --datadir
This commit is contained in:
parent
641ebbde54
commit
775eefee71
@ -307,7 +307,9 @@ int main(int argc, char *argv[]) {
|
||||
QString datadir ;
|
||||
if ((i+1) < args.size()) {
|
||||
datadir = args[++i];
|
||||
settings.setValue("Settings/AppData", homeDocs+datadir);
|
||||
if (datadir.length() < 2 || datadir.at(1) != ":") // Allow a Windows driver letter (but not UNC)
|
||||
datadir = homeDocs+datadir;
|
||||
settings.setValue("Settings/AppData", datadir);
|
||||
// force_data_dir = true;
|
||||
} else {
|
||||
fprintf(stderr, "Missing argument to --datadir\n");
|
||||
|
Loading…
Reference in New Issue
Block a user