From 23eb1c9c34d1a15941b34198a8394b2901122574 Mon Sep 17 00:00:00 2001 From: falkTX Date: Fri, 5 Jul 2013 22:34:59 +0100 Subject: [PATCH] Fix "ps" usage, closes #57 --- data/cadence | 2 +- data/cadence-pulse2jack | 2 +- data/catia | 2 +- data/claudia | 2 +- data/claudia-launcher | 2 +- src/shared_cadence.py | 2 +- 6 files changed, 6 insertions(+), 6 deletions(-) diff --git a/data/cadence b/data/cadence index fa5d327..c16d8a3 100755 --- a/data/cadence +++ b/data/cadence @@ -2,7 +2,7 @@ # Check if already running -PROCS=`ps -ea -f | grep /share/cadence/src/cadence.py | grep python` +PROCS=`ps -f -u $USER | grep /share/cadence/src/cadence.py | grep python` if [ x"$PROCS" != x"" ]; then diff --git a/data/cadence-pulse2jack b/data/cadence-pulse2jack index d24a668..d555390 100755 --- a/data/cadence-pulse2jack +++ b/data/cadence-pulse2jack @@ -80,7 +80,7 @@ esac IsPulseAudioRunning() { - PROCESS=`ps -e | grep pulseaudio` + PROCESS=`ps -u $USER | grep pulseaudio` if [ "$PROCESS" == "" ]; then false else diff --git a/data/catia b/data/catia index e7db0a3..012d5e2 100755 --- a/data/catia +++ b/data/catia @@ -2,7 +2,7 @@ # Check if already running -PROCS=`ps -ea -f | grep /share/cadence/src/catia.py | grep python` +PROCS=`ps -f -u $USER | grep /share/cadence/src/catia.py | grep python` if [ x"$PROCS" != x"" ]; then diff --git a/data/claudia b/data/claudia index 3510dea..4517c51 100755 --- a/data/claudia +++ b/data/claudia @@ -2,7 +2,7 @@ # Check if already running -PROCS=`ps -ea -f | grep /share/cadence/src/claudia.py | grep python` +PROCS=`ps -f -u $USER | grep /share/cadence/src/claudia.py | grep python` if [ x"$PROCS" != x"" ]; then diff --git a/data/claudia-launcher b/data/claudia-launcher index ef8bd56..cec6538 100755 --- a/data/claudia-launcher +++ b/data/claudia-launcher @@ -2,7 +2,7 @@ # Check if already running -PROCS=`ps -ea -f | grep /share/cadence/src/claudia-launcher.py | grep python` +PROCS=`ps -f -u $USER | grep /share/cadence/src/claudia-launcher.py | grep python` if [ x"$PROCS" != x"" ]; then diff --git a/src/shared_cadence.py b/src/shared_cadence.py index 8f1b020..2126dac 100644 --- a/src/shared_cadence.py +++ b/src/shared_cadence.py @@ -76,7 +76,7 @@ def getProcList(): if HAIKU or LINUX or MACOS: process = QProcess() - process.start("ps", ["-e"]) + process.start("ps", ["-u", str(os.getuid())]) process.waitForFinished() processDump = process.readAllStandardOutput().split("\n")