Commit 6e43f873 authored by Alexandre Julliard's avatar Alexandre Julliard

krnl386: Make MapLS argument non-const to avoid some compiler warnings.

parent 1afa20ae
......@@ -249,8 +249,8 @@ static UINT_PTR CALLBACK call_hook_proc( WNDPROC16 hook, HWND hwnd, UINT msg, WP
CREATESTRUCT16 cs;
CREATESTRUCT32Ato16( cs32, &cs );
cs.lpszName = MapLS( cs32->lpszName );
cs.lpszClass = MapLS( cs32->lpszClass );
cs.lpszName = MapLS( (void *)cs32->lpszName );
cs.lpszClass = MapLS( (void *)cs32->lpszClass );
lp = MapLS( &cs );
ret = call_hook16( hook, hwnd, msg, wp, lp );
UnMapLS( lp );
......
......@@ -515,7 +515,7 @@ static struct mapls_entry *first_entry;
*
* Maps linear pointer to segmented.
*/
SEGPTR WINAPI MapLS( LPCVOID ptr )
SEGPTR WINAPI MapLS( void *ptr )
{
struct mapls_entry *entry, *free = NULL;
const void *base;
......
......@@ -670,7 +670,7 @@ HINSTANCE16 WINAPI ShellExecute16( HWND16 hWnd, LPCSTR lpOperation,
* Only exported from shell32 on Windows, probably imported
* from shell through the 16/32 thunks.
*/
void WINAPI RunDLL_CallEntry16( DWORD proc, HWND hwnd, HINSTANCE inst, LPCSTR cmdline, INT cmdshow )
void WINAPI RunDLL_CallEntry16( DWORD proc, HWND hwnd, HINSTANCE inst, LPSTR cmdline, INT cmdshow )
{
WORD args[5];
SEGPTR cmdline_seg;
......
......@@ -186,7 +186,7 @@ static BOOL DIALOG_CreateControls16( HWND hwnd, LPCSTR template,
SEGPTR segptr;
template = DIALOG_GetControl16( template, &info );
segptr = MapLS( info.data );
segptr = MapLS( (void *)info.data );
caption = (char *)info.windowName;
if (caption && IS_INTRESOURCE(caption))
......
......@@ -290,8 +290,8 @@ static LRESULT CALLBACK call_WH_CBT( INT code, WPARAM wp, LPARAM lp )
cs16.y = cbtcw32->lpcs->y;
cs16.x = cbtcw32->lpcs->x;
cs16.style = cbtcw32->lpcs->style;
cs16.lpszName = MapLS( cbtcw32->lpcs->lpszName );
cs16.lpszClass = MapLS( cbtcw32->lpcs->lpszClass );
cs16.lpszName = MapLS( (void *)cbtcw32->lpcs->lpszName );
cs16.lpszClass = MapLS( (void *)cbtcw32->lpcs->lpszClass );
cs16.dwExStyle = cbtcw32->lpcs->dwExStyle;
cbtcw16.lpcs = (CREATESTRUCT16 *)MapLS( &cs16 );
......
......@@ -945,15 +945,15 @@ LRESULT WINPROC_CallProc32ATo16( winproc_callback16_t callback, HWND hwnd, UINT
BOOL mdi_child = (GetWindowLongW(hwnd, GWL_EXSTYLE) & WS_EX_MDICHILD);
CREATESTRUCT32Ato16( cs32, &cs );
cs.lpszName = MapLS( cs32->lpszName );
cs.lpszClass = MapLS( cs32->lpszClass );
cs.lpszName = MapLS( (void *)cs32->lpszName );
cs.lpszClass = MapLS( (void *)cs32->lpszClass );
if (mdi_child)
{
MDICREATESTRUCTA *mdi_cs = cs32->lpCreateParams;
MDICREATESTRUCT32Ato16( mdi_cs, &mdi_cs16 );
mdi_cs16.szTitle = MapLS( mdi_cs->szTitle );
mdi_cs16.szClass = MapLS( mdi_cs->szClass );
mdi_cs16.szTitle = MapLS( (void *)mdi_cs->szTitle );
mdi_cs16.szClass = MapLS( (void *)mdi_cs->szClass );
cs.lpCreateParams = MapLS( &mdi_cs16 );
}
lParam = MapLS( &cs );
......@@ -975,8 +975,8 @@ LRESULT WINPROC_CallProc32ATo16( winproc_callback16_t callback, HWND hwnd, UINT
MDICREATESTRUCT16 cs;
MDICREATESTRUCT32Ato16( cs32, &cs );
cs.szTitle = MapLS( cs32->szTitle );
cs.szClass = MapLS( cs32->szClass );
cs.szTitle = MapLS( (void *)cs32->szTitle );
cs.szClass = MapLS( (void *)cs32->szClass );
lParam = MapLS( &cs );
ret = callback( HWND_16(hwnd), msg, wParam, lParam, result, arg );
UnMapLS( lParam );
......
......@@ -1671,7 +1671,7 @@ BOOL16 WINAPI GetClassInfoEx16( HINSTANCE16 hInst16, SEGPTR name, WNDCLASSEX16 *
wc->hCursor = get_icon_16( wc32.hCursor );
wc->hbrBackground = HBRUSH_16(wc32.hbrBackground);
wc->lpszClassName = 0;
wc->lpszMenuName = MapLS(wc32.lpszMenuName); /* FIXME: leak */
wc->lpszMenuName = MapLS((void *)wc32.lpszMenuName); /* FIXME: leak */
}
return ret;
}
......
......@@ -402,8 +402,8 @@ WORD WINAPI LocalHeapSize16(void);
BOOL16 WINAPI LocalInit16(HANDLE16,WORD,WORD);
FARPROC16 WINAPI LocalNotify16(FARPROC16);
HTASK16 WINAPI LockCurrentTask16(BOOL16);
DWORD WINAPI MapLS(LPCVOID);
LPVOID WINAPI MapSL(DWORD);
SEGPTR WINAPI MapLS(void*);
LPVOID WINAPI MapSL(SEGPTR);
VOID WINAPI OldYield16(void);
VOID WINAPI WIN32_OldYield16(void);
VOID WINAPI PostEvent16(HTASK16);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment