diff options
author | Markus Teich <markus.teich@stusta.mhn.de> | 2015-02-26 14:38:03 +0100 |
---|---|---|
committer | Pablo Neira Ayuso <pablo@netfilter.org> | 2015-03-02 12:05:26 +0100 |
commit | 9ac5b6fb437e24c328a30776e30c39b906b06f66 (patch) | |
tree | fba3393d17a80434a15a229e3a3f71b2fd7b44e4 | |
parent | c9f19b98cd8e108617e825e071091df14f78c53a (diff) | |
download | libmnl-9ac5b6fb437e24c328a30776e30c39b906b06f66.tar.gz libmnl-9ac5b6fb437e24c328a30776e30c39b906b06f66.zip |
header: use sysconf() instead of getpagesize()
The sysconf(_SC_PAGESIZE) call is more portable since it does not need
_BSD_SOURCE defined.
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
-rw-r--r-- | include/libmnl/libmnl.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/include/libmnl/libmnl.h b/include/libmnl/libmnl.h index 0de6678..3a589bc 100644 --- a/include/libmnl/libmnl.h +++ b/include/libmnl/libmnl.h @@ -17,7 +17,7 @@ extern "C" { */ #define MNL_SOCKET_AUTOPID 0 -#define MNL_SOCKET_BUFFER_SIZE (getpagesize() < 8192L ? getpagesize() : 8192L) +#define MNL_SOCKET_BUFFER_SIZE (sysconf(_SC_PAGESIZE) < 8192L ? sysconf(_SC_PAGESIZE) : 8192L) struct mnl_socket; |