kernelbase: Query FileStandardInformation instead of FileEndOfFileInformation in SetFilePointerEx().
Signed-off-by: Paul Gofman <pgofman@codeweavers.com> Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
parent
a0324df70c
commit
b3132be819
|
@ -3621,7 +3621,7 @@ BOOL WINAPI DECLSPEC_HOTPATCH SetFilePointerEx( HANDLE file, LARGE_INTEGER dista
|
||||||
LONGLONG pos;
|
LONGLONG pos;
|
||||||
IO_STATUS_BLOCK io;
|
IO_STATUS_BLOCK io;
|
||||||
FILE_POSITION_INFORMATION info;
|
FILE_POSITION_INFORMATION info;
|
||||||
FILE_END_OF_FILE_INFORMATION eof;
|
FILE_STANDARD_INFORMATION eof;
|
||||||
|
|
||||||
switch(method)
|
switch(method)
|
||||||
{
|
{
|
||||||
|
@ -3634,7 +3634,7 @@ BOOL WINAPI DECLSPEC_HOTPATCH SetFilePointerEx( HANDLE file, LARGE_INTEGER dista
|
||||||
pos = info.CurrentByteOffset.QuadPart + distance.QuadPart;
|
pos = info.CurrentByteOffset.QuadPart + distance.QuadPart;
|
||||||
break;
|
break;
|
||||||
case FILE_END:
|
case FILE_END:
|
||||||
if (NtQueryInformationFile( file, &io, &eof, sizeof(eof), FileEndOfFileInformation ))
|
if (NtQueryInformationFile( file, &io, &eof, sizeof(eof), FileStandardInformation ))
|
||||||
goto error;
|
goto error;
|
||||||
pos = eof.EndOfFile.QuadPart + distance.QuadPart;
|
pos = eof.EndOfFile.QuadPart + distance.QuadPart;
|
||||||
break;
|
break;
|
||||||
|
|
Loading…
Reference in New Issue