#include <sys/stat.h>
#include <unistd.h>
#ifdef HAVE_LINUX_MEMFD_H
-# include <linux/memfd.h>
+#include <linux/memfd.h>
#endif
#include <stdio.h>
#include <sys/mman.h>
return r == (F_SEAL_SHRINK | F_SEAL_GROW | F_SEAL_WRITE | F_SEAL_SEAL);
}
+#endif // 0
int memfd_get_size(int fd, uint64_t *sz) {
struct stat stat;
*sz = stat.st_size;
return 0;
}
-#endif // 0
int memfd_set_size(int fd, uint64_t sz) {
int r;