Commit 7df56c9b authored by Jacek Caban's avatar Jacek Caban Committed by Alexandre Julliard

winemac: Use __wine_unix_call.

parent 218e4698
......@@ -27,8 +27,7 @@ WINE_DEFAULT_DEBUG_CHANNEL(macdrv);
HMODULE macdrv_module = 0;
static unixlib_handle_t macdrv_handle;
NTSTATUS (CDECL *macdrv_unix_call)(enum macdrv_funcs code, void *params);
unixlib_handle_t macdrv_handle;
struct quit_info {
HWND *wins;
......@@ -414,12 +413,10 @@ static BOOL process_attach(void)
str->len = LoadStringW(macdrv_module, str->id, (WCHAR *)&str->str, 0);
params.strings = strings;
if (__wine_unix_call(macdrv_handle, unix_init, &params)) return FALSE;
if (MACDRV_CALL(init, &params)) return FALSE;
callback_table = NtCurrentTeb()->Peb->KernelCallbackTable;
memcpy( callback_table + NtUserDriverCallbackFirst, kernel_callbacks, sizeof(kernel_callbacks) );
macdrv_unix_call = params.unix_call;
return TRUE;
}
......
......@@ -429,9 +429,6 @@ static void load_strings(struct localized_string *str)
}
static NTSTATUS CDECL unix_call( enum macdrv_funcs code, void *params );
/***********************************************************************
* macdrv_init
*/
......@@ -458,8 +455,6 @@ static NTSTATUS macdrv_init(void *arg)
init_user_driver();
macdrv_init_display_devices(FALSE);
params->unix_call = unix_call;
return STATUS_SUCCESS;
}
......@@ -658,10 +653,3 @@ const unixlib_entry_t __wine_unix_call_funcs[] =
};
C_ASSERT( ARRAYSIZE(__wine_unix_call_funcs) == unix_funcs_count );
/* FIXME: Use __wine_unix_call instead */
static NTSTATUS CDECL unix_call(enum macdrv_funcs code, void *params)
{
return __wine_unix_call_funcs[code]( params );
}
......@@ -35,9 +35,8 @@ enum macdrv_funcs
unix_funcs_count
};
/* FIXME: Use __wine_unix_call when the rest of the stack is ready */
extern NTSTATUS (CDECL *macdrv_unix_call)(enum macdrv_funcs code, void *params) DECLSPEC_HIDDEN;
#define MACDRV_CALL(func, params) macdrv_unix_call(unix_ ## func, params)
extern unixlib_handle_t macdrv_handle DECLSPEC_HIDDEN;
#define MACDRV_CALL(func, params) __wine_unix_call(macdrv_handle, unix_ ## func, params)
/* macdrv_dnd_get_data params */
struct dnd_get_data_params
......@@ -84,7 +83,6 @@ struct localized_string
struct init_params
{
struct localized_string *strings;
NTSTATUS (CDECL *unix_call)(enum macdrv_funcs code, void *params);
};
/* macdrv_notify_icon params */
......
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