Files
containerd/archive
Artem Khramov 2bffb5f9b2 FreeBSD: fix tar headers & the nil check on getxattr
On FreeBSD + zfs, stat call seem to return garbage in RDev for regular
files & folders. The value returned is large enough not to fit into
`Devmajor` & `Devminor` fields of the tar header. Fortunately, these
fields are required just for special devices.

This change

* adds a check into `setHeaderForSpecialDevice` that the
  input header represents a special device. If it's not the case, we
  don't set the Devmajor & Devminor fields.

* fixes the nil check on `getxattr`: it never returns nils, but rather
  an empty slice instead

Signed-off-by: Artem Khramov <akhramov@pm.me>
2021-09-21 19:22:41 +03:00
..
2018-12-14 23:18:42 +08:00
2018-05-22 17:08:38 -04:00
2021-08-05 22:27:46 -07:00
2021-08-05 22:27:46 -07:00
2021-08-22 09:31:50 +09:00
2021-08-05 22:27:46 -07:00
2021-08-05 22:27:46 -07:00
2021-08-22 09:31:50 +09:00
2018-02-19 10:32:26 +09:00
2018-02-19 10:32:26 +09:00