Fix FreeBSD compilation

Corrects compile on FreeBSD by handling the lack of ENODATA on FreeBSD.
Since continuity project has already handled this, using their const is
simpler than separating a few extra files in containerd/containerd.

Signed-off-by: Phil Estes <estesp@linux.vnet.ibm.com>
This commit is contained in:
Phil Estes
2017-09-06 14:38:07 -04:00
parent bf08f7cd08
commit 8b938b00bc
2 changed files with 3 additions and 4 deletions

View File

@@ -123,7 +123,7 @@ func handleLChmod(hdr *tar.Header, path string, hdrInfo os.FileInfo) error {
func getxattr(path, attr string) ([]byte, error) {
b, err := sysx.LGetxattr(path, attr)
if err == unix.ENOTSUP || err == unix.ENODATA {
if err == unix.ENOTSUP || err == sysx.ENODATA {
return nil, nil
}
return b, err