From d4dafff85b09a55379305d1b2b7b8d28c739d432 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Aur=C3=A9lien=20Deroide?= Date: Tue, 14 Jun 2022 11:26:14 +0200 Subject: [PATCH] Make *Error implement Unwrap --- xattr.go | 2 ++ 1 file changed, 2 insertions(+) diff --git a/xattr.go b/xattr.go index f982da3..8b2b5fe 100644 --- a/xattr.go +++ b/xattr.go @@ -29,6 +29,8 @@ type Error struct { Err error } +func (e *Error) Unwrap() error { return e.Err } + func (e *Error) Error() (errstr string) { if e.Op != "" { errstr += e.Op