prevent crash resolving /proc/self/exe

This commit is contained in:
Gustavo Iñiguez Goia 2022-07-09 22:17:17 +02:00
parent 45212db908
commit 7557faf3a6

View file

@ -275,7 +275,7 @@ func (p *Process) CleanPath() {
}
// link read failed
if p.Args[0] != "" {
if len(p.Args) > 0 && p.Args[0] != "" {
p.Path = p.Args[0]
return
}