[ scummvm-Bugs-1846545 ] MAIN.CPP Patch for ~ on Linux/Unix systems
SourceForge.net
noreply at sourceforge.net
Fri Dec 7 23:39:21 CET 2007
Bugs item #1846545, was opened at 2007-12-07 23:39
Message generated for change (Tracker Item Submitted) made by Item Submitter
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=418820&aid=1846545&group_id=37116
Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: Launcher/Install
Group: None
Status: Open
Resolution: None
Priority: 5
Private: No
Submitted By: D_Skywalk (d_skywalk)
Assigned to: Nobody/Anonymous (nobody)
Summary: MAIN.CPP Patch for ~ on Linux/Unix systems
Initial Comment:
I submit a simple patch for work "~" on paths in scummvmrc file:
Ex:
[atlantis]
description=Test for scummvm team
path=~/dirgames/game
platform=pc
language=es
CODE (main.cpp)
_______________
static int runGame(const Plugin *plugin, OSystem &system, const Common::String &edebuglevels) {
Common::String gameDataPath(ConfMan.get("path"));
+ #if defined(UNIX)
+ if(gameDataPath.hasPrefix("~/")){
+ gameDataPath.deleteChar(0);
+ gameDataPath = getenv("HOME") + gameDataPath;
+ }
+ #endif
if (gameDataPath.empty()) {
} else if (gameDataPath.lastChar() != '/'
____________________________
Cu guys!
----------------------------------------------------------------------
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=418820&aid=1846545&group_id=37116
More information about the Scummvm-tracker
mailing list