Changeset 4441 for trunk/src


Ignore:
Timestamp:
Oct 6, 2000, 1:04:42 PM (25 years ago)
Author:
sandervl
Message:

console change for pe loader

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/peldr/pe.cpp

    r4231 r4441  
    1 /* $Id: pe.cpp,v 1.21 2000-09-10 21:54:44 sandervl Exp $ */
     1/* $Id: pe.cpp,v 1.22 2000-10-06 11:04:42 sandervl Exp $ */
    22
    33/*
     
    6363
    6464//should be the same as in ..\kernel32\winexepeldr.h
    65 typedef BOOL (* WIN32API WIN32CTOR)(char *, char *, ULONG);
    66 
    67 WIN32CTOR              CreateWin32Exe       = 0;
    68 
    69 ULONG                  reservedMemory       = 0;
     65typedef BOOL (* WIN32API WIN32CTOR)(char *, char *, ULONG, BOOL);
     66
     67WIN32CTOR   CreateWin32Exe       = 0;
     68ULONG       reservedMemory       = 0;
     69BOOL        fConsoleApp          = FALSE;
    7070
    7171void AllocateExeMem(char *filename);
     
    186186        goto fail;
    187187  }
    188   rc = DosQueryProcAddr(hmodKernel32, 0, "_CreateWin32PeLdrExe@12", (PFN *)&CreateWin32Exe);
    189 
    190   if(CreateWin32Exe(exeName, win32cmdline, reservedMemory) == FALSE) {
     188  rc = DosQueryProcAddr(hmodKernel32, 0, "_CreateWin32PeLdrExe@16", (PFN *)&CreateWin32Exe);
     189
     190  if(CreateWin32Exe(exeName, win32cmdline, reservedMemory, fConsoleApp) == FALSE) {
    191191        goto fail;
    192192  }
     
    272272        goto end;
    273273  }
    274 //  if(!(fh.Characteristics & IMAGE_FILE_RELOCS_STRIPPED)) {
    275 //      goto end; //no need to allocate anything now
    276 //  }
     274  fConsoleApp = (oh.Subsystem == IMAGE_SUBSYSTEM_WINDOWS_CUI);
    277275
    278276  // check for high memory support
Note: See TracChangeset for help on using the changeset viewer.