search for: deviceio

Displaying 1 result from an estimated 1 matches for "deviceio".

Did you mean: deviceid
2008 May 06
4
DeviceIoControl + IOCTL_DISK_GET_DRIVE_GEOMETRY problem
Hi all, Ok, what am I doing wrong here? require ''windows/device_io'' require ''windows/handle'' require ''windows/error'' include Windows::DeviceIO include Windows::Handle include Windows::Error fh = File.open(''test.txt'') # Assume you have this handle = get_osfhandle(fh.fileno) if handle == INVALID_HANDLE_VALUE puts "get_osfhandle failed" fh.close exit end buf = 0.chr * 24 # sizeof(DISK_GEOMETRY) byt...