Skip to content

Commit

Permalink
Fix bug to allow for multiple PIDs to be returned
Browse files Browse the repository at this point in the history
Bug:
```
[root@pronghorn04 ~]# service salt-minion restart
Stopping salt-minion daemon:                               [  OK  ]
Starting salt-minion daemon: /etc/init.d/salt-minion: line 67: [: 22610:
unary operator expected
                                                           [  OK  ]
```

Traced bug:
```
++ pidof -c -o 21702 -o 21341 -o %PPID -x salt-minion
+ '[' 22610 7606 ']'
/etc/init.d/salt-minion: line 67: [: 22610: unary operator expected
```
  • Loading branch information
Nathan Rini committed Jan 15, 2014
1 parent 712aa78 commit 73a839d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pkg/rpm/salt-minion
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ start() {
RETVAL=0
fi
else
if [[ $(pidofproc $PROCESS) ]]; then
if [[ ! -z "$(pidofproc $PROCESS)" ]]; then
RETVAL=$?
echo -n "already running"
else
Expand Down

0 comments on commit 73a839d

Please sign in to comment.