Date:2012-10-23 16:34:01 (11 years 5 months ago)
Author:Paul Cercueil
Commit:0b922e97f3eca9e47fe9ac9dc6c7e1e4e40a59b5
Message:For non-OPK programs, chdir() to the app's directory as well

Files: src/linkapp.cpp (1 diff)

Change Details

src/linkapp.cpp
527527        exec = opkMount + exec;
528528    }
529529
530#else
530    else {
531#endif
531532    //Set correct working directory
532533    string::size_type pos = exec.rfind("/");
533534    if (pos != string::npos) {
534535        string wd = exec.substr(0, pos + 1);
535536        chdir(wd.c_str());
536        exec = exec.substr(pos + 1);
537        exec = wd + exec.substr(pos + 1);
538        DEBUG("Changed working directory to %s\n", wd.c_str());
539    }
540#ifdef HAVE_LIBOPK
537541    }
538542#endif
539543

Archive Download the corresponding diff file



interactive