Ignore:
Timestamp:
Dec 19, 1999, 6:41:15 PM (26 years ago)
Author:
sandervl
Message:

Fix for loading images (RSRC_LOAD)

File:
1 edited

Legend:

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

    r2072 r2138  
    1 /* $Id: winimagepeldr.cpp,v 1.24 1999-12-14 12:50:46 sandervl Exp $ */
     1/* $Id: winimagepeldr.cpp,v 1.25 1999-12-19 17:41:15 sandervl Exp $ */
    22
    33/*
     
    301301   if ((psh = (PIMAGE_SECTION_HEADER)SECTIONHDROFF (win32file)) != NULL) {
    302302    dprintf((LOG, "*************************PE SECTIONS START**************************" ));
    303     for (i=0; i<nSections; i++) {
    304         dprintf((LOG, "Raw data size:       %x", psh[i].SizeOfRawData ));
    305         dprintf((LOG, "Virtual Address:     %x", psh[i].VirtualAddress ));
    306         dprintf((LOG, "Virtual Size:        %x", psh[i].Misc.VirtualSize ));
    307         dprintf((LOG, "Pointer to raw data: %x", psh[i].PointerToRawData ));
    308         dprintf((LOG, "Section flags:       %x\n\n", psh[i].Characteristics ));
     303    for (i=0; i<nSections; i++) {
     304        dprintf((LOG, "Raw data size:        %x", psh[i].SizeOfRawData ));
     305        dprintf((LOG, "Virtual Address:      %x", psh[i].VirtualAddress ));
     306        dprintf((LOG, "Virtual Address Start:%x", psh[i].VirtualAddress+oh.ImageBase ));
     307        dprintf((LOG, "Virtual Address End:  %x", psh[i].VirtualAddress+oh.ImageBase+psh[i].Misc.VirtualSize ));
     308        dprintf((LOG, "Virtual Size:         %x", psh[i].Misc.VirtualSize ));
     309        dprintf((LOG, "Pointer to raw data:  %x", psh[i].PointerToRawData ));
     310        dprintf((LOG, "Section flags:        %x\n\n", psh[i].Characteristics ));
    309311        if(strcmp(psh[i].Name, ".reloc") == 0) {
    310312            dprintf((LOG, ".reloc" ));
     
    505507#ifdef COMMIT_ALL
    506508  else {
    507    for (i=0; i<nSections; i++) {
    508         commitPage((ULONG)section[i].realvirtaddr, FALSE, COMPLETE_SECTION);
    509    }
     509        commitPage((ULONG)section[0].realvirtaddr, FALSE, COMPLETE_SECTION);
    510510  }
    511511#endif
     
    559559  rc = DosQueryMem((PVOID)virtAddress, &range, &attr);
    560560  if(rc) {
    561         dprintf((LOG, "Win32PeLdrImage::commitPage: DosQueryMem returned %d", rc));
     561        dprintf((LOG, "Win32PeLdrImage::commitPage: DosQueryMem for %x returned %d", virtAddress, rc));
    562562        return FALSE;
    563563  }
Note: See TracChangeset for help on using the changeset viewer.