VirtualBox

vbox的更動 61936 路徑 trunk/src/VBox/Runtime


忽略:
時間撮記:
2016-6-29 下午04:08:10 (8 年 以前)
作者:
vboxsync
訊息:

nits

檔案:
修改 1 筆資料

圖例:

未更動
新增
刪除
  • trunk/src/VBox/Runtime/common/ldr/ldrPE.cpp

    r60715 r61936  
    528528        PIMAGE_SECTION_HEADER pSH = pModPe->paSections;
    529529        for (unsigned cLeft = pModPe->cSections; cLeft > 0; cLeft--, pSH++)
    530             if (pSH->SizeOfRawData && pSH->Misc.VirtualSize)
    531             {
    532                 rc = pReader->pfnRead(pReader, (uint8_t *)pvBits + pSH->VirtualAddress, pSH->SizeOfRawData, pSH->PointerToRawData);
     530            if (   pSH->SizeOfRawData
     531                && pSH->Misc.VirtualSize
     532                && !(pSH->Characteristics & IMAGE_SCN_TYPE_NOLOAD))
     533            {
     534                uint32_t const cbToRead = RT_MIN(pSH->SizeOfRawData, pModPe->cbImage - pSH->VirtualAddress);
     535                Assert(pSH->VirtualAddress <= pModPe->cbImage);
     536
     537                rc = pReader->pfnRead(pReader, (uint8_t *)pvBits + pSH->VirtualAddress, cbToRead, pSH->PointerToRawData);
    533538                if (RT_FAILURE(rc))
    534539                {
     
    16531658        else
    16541659        {
    1655             SegInfo.LinkAddress = pSh->VirtualAddress + pModPe->uImageBase ;
     1660            SegInfo.LinkAddress = pSh->VirtualAddress + pModPe->uImageBase;
    16561661            SegInfo.RVA         = pSh->VirtualAddress;
    16571662            SegInfo.cbMapped    = RT_ALIGN(SegInfo.cb, SegInfo.Alignment);
注意: 瀏覽 TracChangeset 來幫助您使用更動檢視器

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette