From 930dd83b942fe6083ec119aa2fac9def4a1f350e Mon Sep 17 00:00:00 2001 From: Markus Frosch Date: Fri, 5 Apr 2019 10:34:07 +0200 Subject: [PATCH] windows: Avoid 32-bit linker problems for check_swap --- plugins/check_swap.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/plugins/check_swap.cpp b/plugins/check_swap.cpp index 4f08e2783..dc08f3b3b 100644 --- a/plugins/check_swap.cpp +++ b/plugins/check_swap.cpp @@ -199,7 +199,8 @@ static int printOutput(printInfoStruct& printInfo) static int check_swap(printInfoStruct& printInfo) { - PENUM_PAGE_FILE_CALLBACKW pageFileCallback = &EnumPageFilesProc; + // Needs explicit cast: http://msinilo.pl/blog2/post/p1348/ + PENUM_PAGE_FILE_CALLBACKW pageFileCallback = (PENUM_PAGE_FILE_CALLBACKW)EnumPageFilesProc; std::vector pageFiles; if(!EnumPageFilesW(pageFileCallback, &pageFiles)) {