windows: Avoid 32-bit linker problems for check_swap

This commit is contained in:
Markus Frosch 2019-04-05 10:34:07 +02:00
parent 20fc8960e1
commit 930dd83b94
1 changed files with 2 additions and 1 deletions

View File

@ -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<pageFileInfo> pageFiles;
if(!EnumPageFilesW(pageFileCallback, &pageFiles)) {