Skip to content

Commit

Permalink
Osquerybeat: Fix host_processes missing cmdline arguments (#28622) (#…
Browse files Browse the repository at this point in the history
…28624)

(cherry picked from commit 610e47b)

Co-authored-by: Aleksandr Maus <[email protected]>
  • Loading branch information
mergify[bot] and aleksmaus authored Oct 25, 2021
1 parent b0e1a36 commit 5e13001
Showing 1 changed file with 3 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
package proc

import (
"bytes"
"io/ioutil"
"strings"
)
Expand All @@ -17,5 +18,7 @@ func ReadCmdLine(root string, pid string) (string, error) {
return "", err
}

b = bytes.ReplaceAll(b, []byte{0}, []byte{' '})

return strings.TrimSpace(string(b)), nil
}

0 comments on commit 5e13001

Please sign in to comment.