All pastes #627980 Raw Edit

Stuff

public text v1 · immutable
·published 2007-07-20 17:07 UTC
rendered paste body
void AcrobatSupport::CreateSharedProcess(HANDLE procRoot) {
    HANDLE fPID = fork();
    VOLATILE HANDLE memADDR;

    // create a shared memory space between two processes (e.g. Acrobat3DRenderProc
    // and AcrobatCore).
    if (fPID == 0) {
      memADDR = malloc(AcrobatSupport::IPCSIZE_d);
      if (memADDR == NULL)
        ::error("rww-shp.cpp(2813)", "memADDR = NULL. Open debugger?");
      exit(AcrobatSupport::CreateSharedProcess::SUCCESS_r);
    } else
      while (memADDR == NULL) Sleep(1);
}