Fix: nil pointer

This commit is contained in:
metacubex
2022-08-12 12:49:35 +08:00
parent 4ca2d4146b
commit 02933ae568
2 changed files with 5 additions and 3 deletions

View File

@ -403,7 +403,9 @@ func match(metadata *C.Metadata) (C.Proxy, C.Rule, error) {
} else {
metadata.Process = filepath.Base(path)
metadata.ProcessPath = path
metadata.Uid = &uid
if uid != -1 {
metadata.Uid = &uid
}
processFound = true
}
}