I am using ZwQueryInformationFile to obtain the size of a binary file that contains firmware. Problem is that 3 of the files return the correct size, however two files return a file size off-by-one (-1). So currently I am just doing a cheap hack. I use StandardInformation.EndOfFile.LowPart to obtain the file size in bytes. I really hope this problem is just something simple.
Thanks!