Ignore:
Timestamp:
Mar 24, 2002, 2:10:30 PM (23 years ago)
Author:
sandervl
Message:

all named file mappings are shared

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/kernel32/mmap.cpp

    r7272 r8121  
    1 /* $Id: mmap.cpp,v 1.53 2001-10-30 00:46:17 sandervl Exp $ */
     1/* $Id: mmap.cpp,v 1.54 2002-03-24 13:10:30 sandervl Exp $ */
    22
    33/*
     
    382382        //     when allocating memory with the PAG_ANY bit set. (without this
    383383        //     flag it will also crash)
    384         if(hMemFile == -1 && lpszMapName) {
     384        //All named file mappings are shared (files & memory only)
     385        if(lpszMapName) {
    385386            pMapping = VirtualAllocShared(mSize, fAlloc, PAGE_READWRITE, lpszMapName);
    386387        }
     
    601602        break;
    602603    }
    603     if(map->getMemName() != NULL && map->getFileHandle() == -1 &&
    604        map->getProcessId() != mProcessId)
     604    //Named file mappings from other processes are always shared;
     605    //map into our address space
     606    if(map->getMemName() != NULL && map->getProcessId() != mProcessId)
    605607    {
    606608        //shared memory map, so map it into our address space
Note: See TracChangeset for help on using the changeset viewer.