Details
-
Bug
-
Resolution: Fixed
-
Major
-
None
Description
In kernel32:file wine test there exists this test:
/* try CREATE_ALWAYS over an existing mapping */
|
SetLastError(0xdeadbeef); |
h2 = CreateFileA( filename, GENERIC_WRITE, FILE_SHARE_READ | FILE_SHARE_WRITE,
|
NULL, CREATE_ALWAYS, 0, 0 ); |
ret = GetLastError();
|
if (mapping_modes[a1].dw & SEC_IMAGE) |
{
|
ok( h2 == INVALID_HANDLE_VALUE, "create succeeded for map %s\n", mapping_modes[a1].str ); |
ok( ret == ERROR_SHARING_VIOLATION, "wrong error code %d for %s\n", ret, mapping_modes[a1].str ); |
}
|
The result is this:
(ntoskrnl/mm/section.c:4736) ERROR: File can't be truncated because it has an image section
file.c:2468: Test failed: wrong error code 1224 for SEC_IMAGE | PAGE_WRITECOPY
this might be related to this section in fastfat
This seemingly correct code is disabled by USE_ROS_CC_AND_FS precompiler check, I searched for this in JIRA and came up with nothing.
Currently it seems we reach all the way into VfatSetInformation or some such and attempt to truncate the file and return STATUS_USER_MAPPED_FILE.