Код: Выделить всё
auto hFile = CreateFile(fileName,
GENERIC_READ,
FILE_SHARE_READ, // also tried 0 for exclusive
NULL,
OPEN_EXISTING,
FILE_ATTRIBUTE_NORMAL,
NULL);
if (hFile == INVALID_HANDLE_VALUE) // 0x108
{
DWORD error = GetLastError();
std::wcout
Подробнее здесь: [url]https://stackoverflow.com/questions/78726463/why-may-createfilemapping-throw-error-87[/url]