17 lines
438 B
Plaintext
Raw Normal View History

2024-08-19 11:11:45 +02:00
write(fd Int, address Pointer, length Int) -> Int {
// out numberOfBytesWritten
// out overlapped
return kernel32.WriteFile(fd, address, length)
2024-08-16 12:49:17 +02:00
}
2024-08-19 11:11:45 +02:00
mmap(address Int, length Int, protection Int, flags Int) -> Pointer {
return kernel32.VirtualAlloc(address, length, flags, protection)
2024-08-15 13:53:00 +02:00
}
2024-08-19 17:25:51 +02:00
munmap(address Pointer, length Int) -> Int {
return kernel32.VirtualFree(address, length, 0x4000)
}
2024-08-19 11:11:45 +02:00
exit(code Int) {
kernel32.ExitProcess(code)
2024-08-13 19:34:54 +02:00
}