VirtualBox

Changeset 52960 in vbox for trunk


Ignore:
Timestamp:
Oct 6, 2014 7:55:50 PM (10 years ago)
Author:
vboxsync
Message:

Runtime/memsafer-r3: Ignore calls to SUPR3PageProtect failing with VERR_INVALID_PARAMETER because of the way SUPR3PageAllocEx works on OS X

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Runtime/r3/memsafer-r3.cpp

    r52399 r52960  
    288288         * Configure the guard pages.
    289289         * SUPR3PageProtect isn't supported on all hosts, we ignore that.
     290         * Additionally on darwin we cannot allocate pages without a R0 mapping and
     291         * SUPR3PageAllocEx falls back to another method which is incompatible with
     292         * the way SUPR3PageProtect works, it returns VERR_INVALID_PARAMETER. Ignore that case too.
    290293         */
    291294        rc = SUPR3PageProtect(pvPages, NIL_RTR0PTR, 0, PAGE_SIZE, RTMEM_PROT_NONE);
     
    297300            SUPR3PageProtect(pvPages, NIL_RTR0PTR, 0, PAGE_SIZE, RTMEM_PROT_READ | RTMEM_PROT_WRITE);
    298301        }
    299         else if (rc == VERR_NOT_SUPPORTED)
     302        else if (rc == VERR_NOT_SUPPORTED || rc == VERR_INVALID_PARAMETER)
    300303            return VINF_SUCCESS;
    301304
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