VirtualBox

Changeset 78738 in vbox for trunk/src


Ignore:
Timestamp:
May 24, 2019 11:57:42 PM (6 years ago)
Author:
vboxsync
Message:

Main: Fixed buggy count wraparound handling in GuestBase::generateContextID. bugref:9320

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Main/src-client/GuestCtrlPrivate.cpp

    r78234 r78738  
    902902
    903903    uint32_t uCount = ASMAtomicIncU32(&mNextContextID);
    904     if (uCount >= VBOX_GUESTCTRL_MAX_CONTEXTS)
    905         uCount = 0;
     904    uCount %= VBOX_GUESTCTRL_MAX_CONTEXTS;
    906905
    907906    uint32_t uNewContextID = VBOX_GUESTCTRL_CONTEXTID_MAKE(uSessionID, uObjectID, uCount);
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