VirtualBox

Changeset 25704 in vbox for trunk/include/iprt/critsect.h


Ignore:
Timestamp:
Jan 10, 2010 8:12:30 PM (15 years ago)
Author:
vboxsync
Message:

iprt,pdmcritsect: More flexible lock naming, added RTCritSectSetSubClass and made some RTCritSectInitEx.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/include/iprt/critsect.h

    r25685 r25704  
    125125 *                              order inside the same class.  If you don't know,
    126126 *                              then pass RTLOCKVAL_SUB_CLASS_NONE.
    127  * @param   pszName             The lock name (optional).
     127 * @param   pszNameFmt          Name format string for the lock validator,
     128 *                              optional (NULL). Max length is 32 bytes.
     129 * @param   ...                 Format string arguments.
    128130 */
    129131RTDECL(int) RTCritSectInitEx(PRTCRITSECT pCritSect, uint32_t fFlags,
    130                              RTLOCKVALCLASS hClass, uint32_t uSubClass, const char *pszName);
     132                             RTLOCKVALCLASS hClass, uint32_t uSubClass, const char *pszName, ...);
     133
     134/**
     135 * Changes the lock validator sub-class of the critical section.
     136 *
     137 * It is recommended to try make sure that nobody is using this critical section
     138 * while changing the value.
     139 *
     140 * @returns The old sub-class.  RTLOCKVAL_SUB_CLASS_INVALID is returns if the
     141 *          lock validator isn't compiled in or either of the parameters are
     142 *          invalid.
     143 * @param   pCritSect           The critical section.
     144 * @param   uSubClass           The new sub-class value.
     145 */
     146RTDECL(uint32_t) RTCritSectSetSubClass(PRTCRITSECT pCritSect, uint32_t uSubClass);
    131147
    132148/**
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