Combine stdout and stderr when executing
This commit is contained in:
parent
c262ee3bdf
commit
e8a58e0936
@ -22,7 +22,7 @@ func tracerouteTryExecute(cmd []string, args [][]string) ([]byte, error) {
|
|||||||
var err error
|
var err error
|
||||||
for i := range cmd {
|
for i := range cmd {
|
||||||
instance := exec.Command(cmd[i], args[i]...)
|
instance := exec.Command(cmd[i], args[i]...)
|
||||||
output, err = instance.Output()
|
output, err = instance.CombinedOutput()
|
||||||
if err == nil {
|
if err == nil {
|
||||||
return output, err
|
return output, err
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user