https://git.reactos.org/?p=reactos.git;a=commitdiff;h=830fc82afe6853f8d4e6c…
commit 830fc82afe6853f8d4e6c5e54d6d813c5861fc34
Author: Amine Khaldi <amine.khaldi(a)reactos.org>
AuthorDate: Mon Oct 30 21:48:49 2017 +0100
[SERIALUI] Set the stdcall calling convention for CommDlgProc() and make it return
INT_PTR. CORE-11799 (#94)
---
dll/win32/serialui/serialui.c | 9 ++++-----
dll/win32/serialui/serialui.h | 5 ++++-
2 files changed, 8 insertions(+), 6 deletions(-)
diff --git a/dll/win32/serialui/serialui.c b/dll/win32/serialui/serialui.c
index e4d4d50e17..1e85310440 100644
--- a/dll/win32/serialui/serialui.c
+++ b/dll/win32/serialui/serialui.c
@@ -113,7 +113,7 @@ DWORD WINAPI drvCommConfigDialogW(LPCWSTR lpszDevice,
DialogInfo.lpCC = lpCommConfig;
return DialogBoxParamW(hDllInstance, MAKEINTRESOURCEW(IDD_COMMDLG),
- hWnd, (DLGPROC)CommDlgProc, (LPARAM)&DialogInfo);
+ hWnd, CommDlgProc, (LPARAM)&DialogInfo);
}
/*
@@ -186,10 +186,9 @@ DWORD WINAPI drvGetDefaultCommConfigA(LPCSTR lpszDevice,
*
************************************/
-LRESULT CommDlgProc(HWND hDlg,
- UINT Msg,
- WPARAM wParam,
- LPARAM lParam)
+INT_PTR
+CALLBACK
+CommDlgProc(HWND hDlg, UINT Msg, WPARAM wParam, LPARAM lParam)
{
LPDIALOG_INFO lpDlgInfo = NULL;
HWND hBox;
diff --git a/dll/win32/serialui/serialui.h b/dll/win32/serialui/serialui.h
index f597eac5e1..121d11e281 100644
--- a/dll/win32/serialui/serialui.h
+++ b/dll/win32/serialui/serialui.h
@@ -82,7 +82,10 @@ DWORD WINAPI drvGetDefaultCommConfigA(LPCSTR lpszDevice,
*
************************************/
-LRESULT CommDlgProc(HWND hDlg,
+INT_PTR
+CALLBACK
+CommDlgProc(
+ HWND hDlg,
UINT Msg,
WPARAM wParam,
LPARAM lParam);