VirtualBox

Ignore:
Timestamp:
Jul 12, 2018 9:06:33 PM (6 years ago)
Author:
vboxsync
Message:

*: Made RT_UOFFSETOF, RT_OFFSETOF, RT_UOFFSETOF_ADD and RT_OFFSETOF_ADD work like builtin_offsetof() and require compile time resolvable requests, adding RT_UOFFSETOF_DYN for the dynamic questions that can only be answered at runtime.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/bldprogs/VBoxPeSetVersion.cpp

    r70802 r73097  
    191191
    192192        unsigned long offShdrs = offNtHdrs
    193                                + RT_UOFFSETOF(IMAGE_NT_HEADERS32,
    194                                               OptionalHeader.DataDirectory[NtHdrsNew.x32.OptionalHeader.NumberOfRvaAndSizes]);
     193                               + RT_UOFFSETOF_DYN(IMAGE_NT_HEADERS32,
     194                                                  OptionalHeader.DataDirectory[NtHdrsNew.x32.OptionalHeader.NumberOfRvaAndSizes]);
    195195        if (fseek(pFile, offShdrs, SEEK_SET) != 0)
    196196            return Error("Failed to seek to section headers at %#lx: %s", offShdrs, strerror(errno));
Note: See TracChangeset for help on using the changeset viewer.

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