| ... | ... | @@ -50,6 +50,9 @@ |
| 50 | 50 | |
| 51 | 51 | __BEGIN_DECLS |
| 52 | 52 | |
| 53 | // zig patch: check target glibc version |
| 54 | # if (__GLIBC__ == 2 && __GLIBC_MINOR__ >= 27) || __GLIBC__ > 2 |
| 55 | |
| 53 | 56 | /* Create a new memory file descriptor. NAME is a name for debugging. |
| 54 | 57 | FLAGS is a combination of the MFD_* constants. */ |
| 55 | 58 | int memfd_create (const char *__name, unsigned int __flags) __THROW; |
| ... | ... | @@ -58,6 +61,8 @@ int memfd_create (const char *__name, unsigned int __flags) __THROW; |
| 58 | 61 | memory. FLAGS is a combination of the MLOCK_* flags above. */ |
| 59 | 62 | int mlock2 (const void *__addr, size_t __length, unsigned int __flags) __THROW; |
| 60 | 63 | |
| 64 | #endif /* if (__GLIBC__ == 2 && __GLIBC_MINOR__ >= 27) || __GLIBC__ > 2 */ |
| 65 | |
| 61 | 66 | /* Allocate a new protection key, with the PKEY_DISABLE_* bits |
| 62 | 67 | specified in ACCESS_RIGHTS. The protection key mask for the |
| 63 | 68 | current thread is updated to match the access privilege for the new |
| ... | ... | @@ -82,4 +87,4 @@ int pkey_mprotect (void *__addr, size_t __len, int __prot, int __pkey) __THROW; |
| 82 | 87 | |
| 83 | 88 | __END_DECLS |
| 84 | 89 | |
| 85 | | #endif /* __USE_GNU */ |
| | \ No newline at end of file |
| 90 | #endif /* __USE_GNU */ |