#include "internal.h"
-#include <unistd.h>
+#include <string.h>
#if defined(PCI_OS_LINUX)
#include "i386-io-linux.h"
}
static void
-conf12_cleanup(struct pci_access *a UNUSED)
+conf12_cleanup(struct pci_access *a)
{
if (conf12_io_enabled > 0)
- conf12_io_enabled = intel_cleanup_io(a);
+ {
+ intel_cleanup_io(a);
+ conf12_io_enabled = -1;
+ }
}
/*
{
struct pci_dev d;
+ memset(&d, 0, sizeof(d));
a->debug("...sanity check");
d.bus = 0;
d.func = 0;