diff options
author | Christian Wiese <chris@opensde.org> | 2014-04-12 03:21:10 +0200 |
---|---|---|
committer | Daniel Borkmann <dborkman@redhat.com> | 2014-04-12 11:28:06 +0200 |
commit | a0e49fe80ba94071e4019edc5bbb128e0db1ec35 (patch) | |
tree | 49bfbb032b97ed1a553d58eceba9a2c22d99560f /built_in.h | |
parent | a4772aa046708acfafdf2957ed756d076821bba5 (diff) |
built_in: changed RUNTIME_PAGE_SIZE to use sysconf(_SC_PAGE_SIZE) instead of getpagesize()
getpagesize(2) is considered legacy and has been dropped with POSIX.1-2001.
See discussion: https://github.com/netsniff-ng/netsniff-ng/pull/112
Signed-off-by: Christian Wiese <chris@opensde.org>
Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
Diffstat (limited to 'built_in.h')
-rw-r--r-- | built_in.h | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -178,7 +178,7 @@ typedef uint8_t u8; # define bug() assert(0) #endif -#define RUNTIME_PAGE_SIZE (getpagesize()) +#define RUNTIME_PAGE_SIZE (sysconf(_SC_PAGE_SIZE)) #define PAGE_MASK (~(RUNTIME_PAGE_SIZE - 1)) #define PAGE_ALIGN(addr) (((addr) + RUNTIME_PAGE_SIZE - 1) & PAGE_MASK) |