pub unsafe extern "C" fn drwrap_wrap_ex(
func: app_pc,
pre_func_cb: Option<unsafe extern "C" fn(wrapcxt: *mut c_void, user_data: *mut *mut c_void)>,
post_func_cb: Option<unsafe extern "C" fn(wrapcxt: *mut c_void, user_data: *mut c_void)>,
user_data: *mut c_void,
flags: uint,
) -> bool_Expand description
Identical to drwrap_wrap() except for two additional parameters: \p user_data, which is passed as the initial value of *user_data to \p pre_func_cb, and \p flags, which are the bitwise combination of the #drwrap_wrap_flags_t and at most one #drwrap_callconv_t.
Specify the calling convention by combining one of the DRWRAP_CALLCONV_* values (of #drwrap_callconv_t) with the flags. It is not allowed to specify multiple calling conventions. If the specified calling convention is incorrect for \p func, the wrap will succeed, but calls to drwrap_set_arg() and drwrap_get_arg() for \p func will either access the wrong argument value, or will access a register or stack slot that does not contain any argument value. If no calling convention is specified, defaults to #DRWRAP_CALLCONV_DEFAULT.
This routine may call dr_unlink_flush_region(), which means that it cannot be called while any locks are held that could block a thread processing a registered event callback or cache callout.