Remove imports of poll.h which are redundant, and
conditionalize remaining usage that needs to compile
on Windows platforms.
Reviewed-by: Pavel Hrdina <phrdina@redhat.com>
Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
*/
#include <config.h>
-#include <poll.h>
#include "virpolkit.h"
#include "virerror.h"
VIR_LOG_INIT("util.polkit");
#if WITH_POLKIT
+# include <poll.h>
struct _virPolkitAgent {
virCommandPtr cmd;
#include <unistd.h>
#include <fcntl.h>
-#include <poll.h>
#include <sys/stat.h>
#ifdef WIN32
#include <unistd.h>
#include <fcntl.h>
#include <sys/stat.h>
-#include <poll.h>
#include "internal.h"
#define NO_LIBVIRT
#include "testutils.h"
#ifndef WIN32
+# include <poll.h>
/* Some UNIX lack it in headers & it doesn't hurt to redeclare */
extern char **environ;