VirtualBox

Changeset 54280 in vbox


Ignore:
Timestamp:
Feb 18, 2015 7:58:17 PM (10 years ago)
Author:
vboxsync
Message:

SUPDrv.c: Fixed bug in IDTR.LIMIT detection.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/HostDrivers/Support/SUPDrv.c

    r54275 r54280  
    40854085             */
    40864086#ifdef RT_ARCH_X86
    4087             uint16_t const  cbIdt = sizeof(X86DESC64SYSTEM);
     4087            uint16_t const  cbIdt = sizeof(X86DESC64SYSTEM) * 256;
    40884088#else
    4089             uint16_t const  cbIdt = sizeof(X86DESCGATE);
     4089            uint16_t const  cbIdt = sizeof(X86DESCGATE)     * 256;
    40904090#endif
    40914091            RTIDTR          Idtr;
     
    41454145     */
    41464146    if (RT_UNLIKELY(   iCpuSet < 0
    4147                     || iCpuSet >= RTCPUSET_MAX_CPUS
    4148                     || iCpuSet >= RT_ELEMENTS(pGip->aiCpuFromCpuSetIdx)))
     4147                    || (unsigned)iCpuSet >= RTCPUSET_MAX_CPUS
     4148                    || (unsigned)iCpuSet >= RT_ELEMENTS(pGip->aiCpuFromCpuSetIdx)))
    41494149    {
    41504150        ASMAtomicCmpXchgU32(&pState->idCpuProblem, idCpu, NIL_RTCPUID);
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