mirror of
https://github.com/ziglang/zig.git
synced 2025-12-06 14:23:09 +00:00
std: improved windows.DeviceIoControl
This commit is contained in:
parent
b05a5a3e52
commit
ce9966a39b
@ -132,6 +132,7 @@ pub fn DeviceIoControl(
|
|||||||
overlapped,
|
overlapped,
|
||||||
) == 0) {
|
) == 0) {
|
||||||
switch (kernel32.GetLastError()) {
|
switch (kernel32.GetLastError()) {
|
||||||
|
ERROR.IO_PENDING => if (overlapped == null) unreachable,
|
||||||
else => |err| return unexpectedError(err),
|
else => |err| return unexpectedError(err),
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -59,7 +59,7 @@ pub extern "kernel32" stdcallcc fn DeviceIoControl(
|
|||||||
nInBufferSize: DWORD,
|
nInBufferSize: DWORD,
|
||||||
lpOutBuffer: ?LPVOID,
|
lpOutBuffer: ?LPVOID,
|
||||||
nOutBufferSize: DWORD,
|
nOutBufferSize: DWORD,
|
||||||
lpBytesReturned: LPDWORD,
|
lpBytesReturned: ?*DWORD,
|
||||||
lpOverlapped: ?*OVERLAPPED,
|
lpOverlapped: ?*OVERLAPPED,
|
||||||
) BOOL;
|
) BOOL;
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user