Merge pull request #141 from ovear/master

fix callps command generate error
This commit is contained in:
shirou 2016-02-02 22:14:17 +09:00
commit 41f99949e3
1 changed files with 2 additions and 2 deletions

View File

@ -415,9 +415,9 @@ func callPs(arg string, pid int32, threadOption bool) ([][]string, error) {
if pid == 0 { // will get from all processes. if pid == 0 { // will get from all processes.
cmd = []string{"-ax", "-o", arg} cmd = []string{"-ax", "-o", arg}
} else if threadOption { } else if threadOption {
cmd = []string{"-ax", "-o", arg, "-M", "-p", strconv.Itoa(int(pid))} cmd = []string{"-x", "-o", arg, "-M", "-p", strconv.Itoa(int(pid))}
} else { } else {
cmd = []string{"-ax", "-o", arg, "-p", strconv.Itoa(int(pid))} cmd = []string{"-x", "-o", arg, "-p", strconv.Itoa(int(pid))}
} }
out, err := invoke.Command(bin, cmd...) out, err := invoke.Command(bin, cmd...)
if err != nil { if err != nil {