shared: guard all the seal logic behind HAVE_MEMFD_CREATE
authorSebastian Wick <sebastian@sebastianwick.net>
Wed, 5 Feb 2020 09:27:23 +0000 (10:27 +0100)
committerSebastian Wick <sebastian@sebastianwick.net>
Wed, 5 Feb 2020 09:40:25 +0000 (10:40 +0100)
commitf0d3a6149158f682230ae9a1e69289431974f635
tree166b2cdf5724115ba58630aa913797fe9820838b
parent7bce28b5433bdbf66dc6c86fb9e129cec354ba89
shared: guard all the seal logic behind HAVE_MEMFD_CREATE

The initial version of os_ro_anonymous_file missed two guards around the
seal logic which leads to a compilation error on older systems.

Also make the check for a read-only file symmetric in
os_ro_anonymous_file_get_fd and os_ro_anonymous_file_put_fd.

Signed-off-by: Sebastian Wick <sebastian@sebastianwick.net>
shared/os-compatibility.c