Commit
bfe7721d introduced a regression, but only on platforms
like FreeBSD that lack posix_fallocate and where mmap serves as
a nice fallback for safezero.
util/virfile.c: In function 'safezero':
util/virfile.c:837: error: 'PROT_READ' undeclared (first use in this function)
* src/util/virutil.c (includes): Move use of <sys/mman.h>...
* src/util/virfile.c (includes): ...to the file that uses mmap.
Signed-off-by: Eric Blake <eblake@redhat.com>
# include <mntent.h>
#endif
#include <stdlib.h>
+#if HAVE_MMAP
+# include <sys/mman.h>
+#endif
#if defined(__linux__) && HAVE_DECL_LO_FLAGS_AUTOCLEAR
# include <linux/loop.h>
#include <sys/stat.h>
#include <sys/types.h>
#include <sys/ioctl.h>
-#if HAVE_MMAP
-# include <sys/mman.h>
-#endif
#include <string.h>
#include <termios.h>
#include <locale.h>