summary refs log tree commit diff
path: root/src/testsuite
diff options
context:
space:
mode:
authorAlexander Barton <alex@barton.de>2013-09-03 21:33:22 +0200
committerAlexander Barton <alex@barton.de>2013-09-03 21:33:22 +0200
commite3a2a6c44d30a68f3afeab17ba19a5559e09f3a5 (patch)
treebb35f3146840f5f8a1c470fb7397a952d8f8ccdf /src/testsuite
parentaad92ceafe8b4b0091867415504f83930a74428b (diff)
downloadngircd-e3a2a6c44d30a68f3afeab17ba19a5559e09f3a5.tar.gz
ngircd-e3a2a6c44d30a68f3afeab17ba19a5559e09f3a5.zip
getpid.sh: use /bin/pidof when available
Diffstat (limited to 'src/testsuite')
-rwxr-xr-xsrc/testsuite/getpid.sh3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/testsuite/getpid.sh b/src/testsuite/getpid.sh
index 96ab4746..f200afb9 100755
--- a/src/testsuite/getpid.sh
+++ b/src/testsuite/getpid.sh
@@ -1,10 +1,11 @@
 #!/bin/sh
 # ngIRCd Test Suite
-# $Id: getpid.sh,v 1.5 2006/08/05 00:15:28 alex Exp $
 
 # did we get a name?
 [ $# -ne 1 ] && exit 1
 
+[ -x /bin/pidof ] && exec /bin/pidof -s $@
+
 # detect flags for "ps" and "head"
 UNAME=`uname`
 if [ $UNAME = "FreeBSD" ]; then