VirtualBox

Changeset 75689 in vbox for trunk/src/VBox/HostDrivers


Ignore:
Timestamp:
Nov 23, 2018 2:27:04 PM (6 years ago)
Author:
vboxsync
Message:

VBoxNetFlt.c: Wrong allocator function for variable sized structures, triggers problems on darwin where we've got EF in ring-0.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/HostDrivers/VBoxNetFlt/VBoxNetFlt.c

    r75687 r75689  
    999999    int             rc;
    10001000    size_t const    cchName = strlen(pszName);
    1001     PVBOXNETFLTINS  pNew = (PVBOXNETFLTINS)RTMemAllocZ(RT_UOFFSETOF_DYN(VBOXNETFLTINS, szName[cchName + 1]));
     1001    PVBOXNETFLTINS  pNew = (PVBOXNETFLTINS)RTMemAllocZVar(RT_UOFFSETOF_DYN(VBOXNETFLTINS, szName[cchName + 1]));
    10021002    if (!pNew)
    10031003        return VERR_INTNET_FLT_IF_FAILED;
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