-
Notifications
You must be signed in to change notification settings - Fork 73
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Can not compile then call original function. #3
Comments
Not quite sure why, try dropping the static_detours! {
struct Send: unsafe extern "system" fn(winapi::SOCKET, *const winapi::c_char, winapi::c_int, winapi::c_int) -> winapi::c_int;
} → static_detours! {
struct Send: extern "system" fn(winapi::SOCKET, *const winapi::c_char, winapi::c_int, winapi::c_int) -> winapi::c_int;
} |
If delete Send.initialize(
ws2_32::send,
| ^^^^^^^^^^^^ expected normal fn, found unsafe fn
|
= note: expected type `extern "system" fn(u64, *const i8, i32, i32) -> i32`
found type `unsafe extern "system" fn(u64, *const i8, i32, i32) -> i32 {ws2_32::send}` |
Okay, this should be fixed in latest master.
|
Yes, latest master fixed this. Thanks. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Hi. I try use detour for
ws2_32::send
.But then i try to execute original function from detour closure:
Code does not compiles.
Error:
Where there can be an error?
The text was updated successfully, but these errors were encountered: