X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/d6a1743b56db3ef0b84d5b84bba94c21612226eb..9406d962ccf50d63f163896a2dd94123a2a8664a:/src/msw/printwin.cpp diff --git a/src/msw/printwin.cpp b/src/msw/printwin.cpp index f60b574725..3e1097e3fb 100644 --- a/src/msw/printwin.cpp +++ b/src/msw/printwin.cpp @@ -175,7 +175,16 @@ bool wxWindowsPrinter::Print(wxWindow *parent, wxPrintout *printout, bool prompt #if defined(__BORLANDC__) || defined(__GNUWIN32__) ::SetAbortProc((HDC) dc->GetHDC(), (FARPROC) lpAbortProc); #else - ::SetAbortProc((HDC) dc->GetHDC(), (int (_stdcall *)(HDC, int)) lpAbortProc); + ::SetAbortProc((HDC) dc->GetHDC(), (int (_stdcall *) + // cast it to right type only if required + // @@@ it's really cdecl and we're casting it to stdcall - either there is + // something I don't understand or it will crash at first usage + #ifdef STRICT + (HDC, int) + #else + () + #endif + )lpAbortProc); #endif if (!win)