projects
/
supertux.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
c11d9d5
)
Correctly parse file:// urls
author
Tobias Markus
<tobbi@mozilla-uk.org>
Sat, 10 May 2014 10:53:58 +0000
(12:53 +0200)
committer
Tobias Markus
<tobbi@mozilla-uk.org>
Sat, 10 May 2014 10:54:05 +0000
(12:54 +0200)
src/supertux/main.cpp
patch
|
blob
|
history
diff --git
a/src/supertux/main.cpp
b/src/supertux/main.cpp
index
e3002fd
..
d78330b
100644
(file)
--- a/
src/supertux/main.cpp
+++ b/
src/supertux/main.cpp
@@
-631,6
+631,11
@@
Main::run(int argc, char** argv)
// we have a normal path specified at commandline, not a physfs path.
// So we simply mount that path here...
std::string dir = FileSystem::dirname(g_config->start_level);
+ std::string fileProtocol = "file://";
+ int position = dir.find(fileProtocol);
+ if(position != std::string::npos) {
+ dir = dir.replace(position, fileProtocol.length(), "");
+ }
log_debug << "Adding dir: " << dir << std::endl;
PHYSFS_addToSearchPath(dir.c_str(), true);