Wrap errors in the Go 1.13 way
Signed-off-by: Julian Kornberger <jk+github@digineo.de>
This commit is contained in:
parent
da0ae76a91
commit
043fecbfd8
21 changed files with 31 additions and 31 deletions
|
|
@ -58,7 +58,7 @@ func (c *meminfoCollector) getMemInfo() (map[string]float64, error) {
|
|||
var bcstats C.struct_bcachestats
|
||||
|
||||
if _, err := C.sysctl_uvmexp(&uvmexp); err != nil {
|
||||
return nil, fmt.Errorf("sysctl CTL_VM VM_UVMEXP failed: %v", err)
|
||||
return nil, fmt.Errorf("sysctl CTL_VM VM_UVMEXP failed: %w", err)
|
||||
}
|
||||
|
||||
if _, err := C.sysctl_bcstats(&bcstats); err != nil {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue