1
0
mirror of https://github.com/systemd/systemd.git synced 2024-12-22 17:35:35 +03:00

nspawn: Include netlink headers rather than using #ifdef

This is a better fix than e13e1fad8b for
failing to compile without audit that
77b6e19458 introduced.
This commit is contained in:
Colin Walters 2013-05-09 19:31:20 -04:00
parent e13e1fad8b
commit 2e996f4d4b

View File

@ -39,6 +39,7 @@
#include <sys/signalfd.h>
#include <grp.h>
#include <linux/fs.h>
#include <linux/netlink.h>
#include <sys/un.h>
#include <sys/socket.h>
@ -1220,7 +1221,6 @@ finish:
}
static bool audit_enabled(void) {
#ifdef HAVE_AUDIT
int fd;
fd = socket(AF_NETLINK, SOCK_RAW, NETLINK_AUDIT);
@ -1228,7 +1228,6 @@ static bool audit_enabled(void) {
close_nointr_nofail(fd);
return true;
}
#endif
return false;
}