Skip to content

Commit

Permalink
fix: capabilites weren't logged properly
Browse files Browse the repository at this point in the history
  • Loading branch information
joshiste committed Aug 24, 2023
1 parent e8133e4 commit 4159d6b
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions extruntime/extruntime_linux.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,10 @@ import (

func logCapsInformation(level zerolog.Level) {
caps, err := exec.Command("getpcaps", strconv.Itoa(os.Getpid())).CombinedOutput()
if err != nil {
if err == nil {
log.WithLevel(level).Msgf("Process capabilities: %s", string(caps))
} else {
log.WithLevel(level).Msgf("Process capabilities: %s", err)
log.WithLevel(level).Msgf("Process capabilities: %s", err.Error())
}
}

Expand Down

0 comments on commit 4159d6b

Please sign in to comment.