Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also compare across forks.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also compare across forks.
...
  • 2 commits
  • 1 file changed
  • 0 commit comments
  • 1 contributor
Commits on Nov 12, 2013
@beanpole135 beanpole135 Make sure that when PCDM is looking for the existance of the "tryexec…
…" *.desktop value it searches the entire PATH rather than just /usr/local/bin
ec44687
@beanpole135 beanpole135 Merge branch 'master' of github.com:pcbsd/pcbsd 1c049ce
Showing with 9 additions and 1 deletion.
  1. +9 −1 src-qt4/PCDM/src/pcdm-backend.cpp
View
10 src-qt4/PCDM/src/pcdm-backend.cpp
@@ -262,6 +262,8 @@ void Backend::loadXSessionsData(){
instXCommentList.clear(); instXIconList.clear();
//Load the default paths/locale
QString xDir = Config::xSessionsDir();
+ QStringList paths = QString(getenv("PATH")).split(":");
+ if(paths.isEmpty()){ paths <<"/usr/local/bin" << "/usr/local/sbin" << "/usr/bin" << "/usr/sbin" << "/bin" << "/sbin"; }
if(!xDir.endsWith("/")){ xDir.append("/"); }
QString xIconDir = Config::xSessionsImageDir();
if(!xIconDir.endsWith("/")){ xIconDir.append("/"); }
@@ -278,7 +280,13 @@ void Backend::loadXSessionsData(){
//Complete file paths if necessary
//if(!tmp[0].startsWith("/")){ tmp[0] = "/usr/local/bin/"+tmp[0]; }
if(!tmp[3].startsWith("/")&&!tmp[3].startsWith(":")&&!tmp[3].isEmpty()){ tmp[3] = xIconDir+tmp[3]; }
- if(!tmp[4].startsWith("/")){ tmp[4] = "/usr/local/bin/"+tmp[4]; }
+ if(!tmp[4].startsWith("/") && !QFile::exists(tmp[4])){
+ for(int p=0; i<paths.length(); i++){
+ if(QFile::exists(paths[p]+"/"+tmp[4])){
+ tmp[4] = paths[p]+"/"+tmp[4];
+ }
+ }
+ }
//Check for valid DE using the "tryexec" line
//this allows for special startup commands on the "exec" line
if(QFile::exists(tmp[4])){

No commit comments for this range

Something went wrong with that request. Please try again.