Skip to content

Commit 879a3c1

Browse files
committed
Restore launching with absolute path
1 parent cdb25b0 commit 879a3c1

File tree

1 file changed

+7
-6
lines changed

1 file changed

+7
-6
lines changed

Source/Main.cpp

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -121,22 +121,23 @@ class OpenEphysApplication : public JUCEApplication
121121
for (auto param : parameters)
122122
{
123123
if (param.equalsIgnoreCase ("--headless"))
124+
{
124125
isConsoleApp = true;
125-
126-
else if (File::createLegalFileName (param).equalsIgnoreCase (param))
126+
}
127+
else if (fileToLoad.getFullPathName().isEmpty())
127128
{
128129
File localPath (File::getCurrentWorkingDirectory().getChildFile (param));
129130

130131
if (localPath.existsAsFile())
131132
{
132133
fileToLoad = localPath;
133-
break;
134+
continue;
134135
}
135136

136-
//File globalPath(param);
137+
File globalPath (param);
137138

138-
//if (globalPath.existsAsFile())
139-
// fileToLoad = globalPath;
139+
if (globalPath.existsAsFile())
140+
fileToLoad = globalPath;
140141
}
141142
}
142143

0 commit comments

Comments
 (0)