VirtualBox

Changeset 25721 in vbox for trunk/src/VBox/Runtime/r3


Ignore:
Timestamp:
Jan 11, 2010 2:01:53 PM (15 years ago)
Author:
vboxsync
Message:

iprt/RTSemMutex: MutexSem -> hMutexSem

Location:
trunk/src/VBox/Runtime/r3
Files:
4 edited

Legend:

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

    r25715 r25721  
    141141
    142142
    143 RTDECL(int)  RTSemMutexDestroy(RTSEMMUTEX MutexSem)
     143RTDECL(int)  RTSemMutexDestroy(RTSEMMUTEX hMutexSem)
    144144{
    145145    /*
    146146     * Validate input.
    147147     */
    148     if (MutexSem == NIL_RTSEMMUTEX)
     148    if (hMutexSem == NIL_RTSEMMUTEX)
    149149        return VINF_SUCCESS;
    150     struct RTSEMMUTEXINTERNAL *pThis = MutexSem;
     150    struct RTSEMMUTEXINTERNAL *pThis = hMutexSem;
    151151    AssertPtrReturn(pThis, VERR_INVALID_HANDLE);
    152152    AssertMsgReturn(pThis->u32Magic == RTSEMMUTEX_MAGIC,
    153                     ("MutexSem=%p u32Magic=%#x\n", pThis, pThis->u32Magic),
     153                    ("hMutexSem=%p u32Magic=%#x\n", pThis, pThis->u32Magic),
    154154                    VERR_INVALID_HANDLE);
    155155
     
    194194
    195195
    196 DECL_FORCE_INLINE(int) rtSemMutexRequest(RTSEMMUTEX MutexSem, unsigned cMillies, bool fAutoResume, PCRTLOCKVALSRCPOS pSrcPos)
     196DECL_FORCE_INLINE(int) rtSemMutexRequest(RTSEMMUTEX hMutexSem, unsigned cMillies, bool fAutoResume, PCRTLOCKVALSRCPOS pSrcPos)
    197197{
    198198    /*
    199199     * Validate input.
    200200     */
    201     struct RTSEMMUTEXINTERNAL *pThis = MutexSem;
     201    struct RTSEMMUTEXINTERNAL *pThis = hMutexSem;
    202202    AssertPtrReturn(pThis, VERR_INVALID_HANDLE);
    203203    AssertReturn(pThis->u32Magic == RTSEMMUTEX_MAGIC, VERR_INVALID_HANDLE);
     
    343343
    344344#undef RTSemMutexRequest
    345 RTDECL(int) RTSemMutexRequest(RTSEMMUTEX MutexSem, unsigned cMillies)
     345RTDECL(int) RTSemMutexRequest(RTSEMMUTEX hMutexSem, unsigned cMillies)
    346346{
    347347#ifndef RTSEMMUTEX_STRICT
    348     int rc = rtSemMutexRequest(MutexSem, cMillies, true, NULL);
     348    int rc = rtSemMutexRequest(hMutexSem, cMillies, true, NULL);
    349349#else
    350350    RTLOCKVALSRCPOS SrcPos = RTLOCKVALSRCPOS_INIT_NORMAL_API();
    351     int rc = rtSemMutexRequest(MutexSem, cMillies, true, &SrcPos);
     351    int rc = rtSemMutexRequest(hMutexSem, cMillies, true, &SrcPos);
    352352#endif
    353353    Assert(rc != VERR_INTERRUPTED);
     
    356356
    357357
    358 RTDECL(int) RTSemMutexRequestDebug(RTSEMMUTEX MutexSem, unsigned cMillies, RTHCUINTPTR uId, RT_SRC_POS_DECL)
     358RTDECL(int) RTSemMutexRequestDebug(RTSEMMUTEX hMutexSem, unsigned cMillies, RTHCUINTPTR uId, RT_SRC_POS_DECL)
    359359{
    360360    RTLOCKVALSRCPOS SrcPos = RTLOCKVALSRCPOS_INIT_DEBUG_API();
    361     int rc = rtSemMutexRequest(MutexSem, cMillies, true, &SrcPos);
     361    int rc = rtSemMutexRequest(hMutexSem, cMillies, true, &SrcPos);
    362362    Assert(rc != VERR_INTERRUPTED);
    363363    return rc;
     
    366366
    367367#undef RTSemMutexRequestNoResume
    368 RTDECL(int) RTSemMutexRequestNoResume(RTSEMMUTEX MutexSem, unsigned cMillies)
     368RTDECL(int) RTSemMutexRequestNoResume(RTSEMMUTEX hMutexSem, unsigned cMillies)
    369369{
    370370#ifndef RTSEMMUTEX_STRICT
    371     return rtSemMutexRequest(MutexSem, cMillies, false, NULL);
     371    return rtSemMutexRequest(hMutexSem, cMillies, false, NULL);
    372372#else
    373373    RTLOCKVALSRCPOS SrcPos = RTLOCKVALSRCPOS_INIT_NORMAL_API();
    374     return rtSemMutexRequest(MutexSem, cMillies, false, &SrcPos);
    375 #endif
    376 }
    377 
    378 
    379 RTDECL(int) RTSemMutexRequestNoResumeDebug(RTSEMMUTEX MutexSem, unsigned cMillies, RTHCUINTPTR uId, RT_SRC_POS_DECL)
     374    return rtSemMutexRequest(hMutexSem, cMillies, false, &SrcPos);
     375#endif
     376}
     377
     378
     379RTDECL(int) RTSemMutexRequestNoResumeDebug(RTSEMMUTEX hMutexSem, unsigned cMillies, RTHCUINTPTR uId, RT_SRC_POS_DECL)
    380380{
    381381    RTLOCKVALSRCPOS SrcPos = RTLOCKVALSRCPOS_INIT_DEBUG_API();
    382     return rtSemMutexRequest(MutexSem, cMillies, false, &SrcPos);
    383 }
    384 
    385 
    386 RTDECL(int) RTSemMutexRelease(RTSEMMUTEX MutexSem)
     382    return rtSemMutexRequest(hMutexSem, cMillies, false, &SrcPos);
     383}
     384
     385
     386RTDECL(int) RTSemMutexRelease(RTSEMMUTEX hMutexSem)
    387387{
    388388    /*
    389389     * Validate input.
    390390     */
    391     struct RTSEMMUTEXINTERNAL *pThis = MutexSem;
     391    struct RTSEMMUTEXINTERNAL *pThis = hMutexSem;
    392392    AssertPtrReturn(pThis, VERR_INVALID_HANDLE);
    393393    AssertReturn(pThis->u32Magic == RTSEMMUTEX_MAGIC, VERR_INVALID_HANDLE);
     
    440440
    441441
    442 RTDECL(bool) RTSemMutexIsOwned(RTSEMMUTEX hMutex)
     442RTDECL(bool) RTSemMutexIsOwned(RTSEMMUTEX hMutexSem)
    443443{
    444444    /*
    445445     * Validate.
    446446     */
    447     RTSEMMUTEXINTERNAL *pThis = hMutex;
     447    RTSEMMUTEXINTERNAL *pThis = hMutexSem;
    448448    AssertPtrReturn(pThis, false);
    449449    AssertReturn(pThis->u32Magic == RTSEMMUTEX_MAGIC, false);
  • trunk/src/VBox/Runtime/r3/os2/sems-os2.cpp

    r25720 r25721  
    247247
    248248
     249RTDECL(void) RTSemEventMultiSetSignaller(RTSEMEVENTMULTI hEventMultiSem, RTTHREAD hThread)
     250{
     251    /** @todo implement RTSemEventMultiSetSignaller on OS/2 */
     252}
     253
     254
     255RTDECL(void) RTSemEventMultiAddSignaller(RTSEMEVENTMULTI hEventMultiSem, RTTHREAD hThread)
     256{
     257}
     258
     259
     260RTDECL(void) RTSemEventMultiRemoveSignaller(RTSEMEVENTMULTI hEventMultiSem, RTTHREAD hThread)
     261{
     262}
     263
    249264
    250265
     
    277292
    278293
    279 RTDECL(int)  RTSemMutexDestroy(RTSEMMUTEX MutexSem)
    280 {
     294RTDECL(int)  RTSemMutexDestroy(RTSEMMUTEX hMutexSem)
     295{
     296    if (hMutexSem == NIL_RTSEMMUTEX)
     297        return VINF_SUCCESS;
     298
    281299    /*
    282300     * Close semaphore handle.
    283301     */
    284     int rc = DosCloseMutexSem(SEM2HND(MutexSem));
    285     if (!rc)
    286         return VINF_SUCCESS;
    287     AssertMsgFailed(("Destroy MutexSem %p failed, rc=%d\n", MutexSem, rc));
     302    int rc = DosCloseMutexSem(SEM2HND(hMutexSem));
     303    if (!rc)
     304        return VINF_SUCCESS;
     305    AssertMsgFailed(("Destroy hMutexSem %p failed, rc=%d\n", hMutexSem, rc));
    288306    return RTErrConvertFromOS2(rc);
    289307}
     
    309327
    310328#undef RTSemMutexRequestNoResume
    311 RTDECL(int)  RTSemMutexRequestNoResume(RTSEMMUTEX MutexSem, unsigned cMillies)
     329RTDECL(int)  RTSemMutexRequestNoResume(RTSEMMUTEX hMutexSem, unsigned cMillies)
    312330{
    313331    /*
    314332     * Lock mutex semaphore.
    315333     */
    316     int rc = DosRequestMutexSem(SEM2HND(MutexSem), cMillies == RT_INDEFINITE_WAIT ? SEM_INDEFINITE_WAIT : cMillies);
     334    int rc = DosRequestMutexSem(SEM2HND(hMutexSem), cMillies == RT_INDEFINITE_WAIT ? SEM_INDEFINITE_WAIT : cMillies);
    317335    switch (rc)
    318336    {
     
    324342        default:
    325343        {
    326             AssertMsgFailed(("Wait on MutexSem %p failed, rc=%d\n", MutexSem, rc));
     344            AssertMsgFailed(("Wait on hMutexSem %p failed, rc=%d\n", hMutexSem, rc));
    327345            return RTErrConvertFromOS2(rc);
    328346        }
     
    330348}
    331349
    332 RTDECL(int)  RTSemMutexRelease(RTSEMMUTEX MutexSem)
     350RTDECL(int)  RTSemMutexRelease(RTSEMMUTEX hMutexSem)
    333351{
    334352    /*
    335353     * Unlock mutex semaphore.
    336354     */
    337     int rc = DosReleaseMutexSem(SEM2HND(MutexSem));
    338     if (!rc)
    339         return VINF_SUCCESS;
    340     AssertMsgFailed(("Release MutexSem %p failed, rc=%d\n", MutexSem, rc));
    341     return RTErrConvertFromOS2(rc);
    342 }
    343 
    344 
    345 RTDECL(bool) RTSemMutexIsOwned(RTSEMMUTEX hMutex);
     355    int rc = DosReleaseMutexSem(SEM2HND(hMutexSem));
     356    if (!rc)
     357        return VINF_SUCCESS;
     358    AssertMsgFailed(("Release hMutexSem %p failed, rc=%d\n", hMutexSem, rc));
     359    return RTErrConvertFromOS2(rc);
     360}
     361
     362
     363RTDECL(bool) RTSemMutexIsOwned(RTSEMMUTEX hMutexSem);
    346364{
    347365    /*
     
    351369    TID     tid;
    352370    ULONG   cRecursions;
    353     int rc = DosQueryMutexSem(SEM2HND(MutexSem), &pid, &tid, &cRecursions);
     371    int rc = DosQueryMutexSem(SEM2HND(hMutexSem), &pid, &tid, &cRecursions);
    354372    if (!rc)
    355373        return cRecursions != 0;
    356     AssertMsgFailed(("DosQueryMutexSem %p failed, rc=%d\n", MutexSem, rc));
     374    AssertMsgFailed(("DosQueryMutexSem %p failed, rc=%d\n", hMutexSem, rc));
    357375    return rc == ERROR_SEM_OWNER_DIED;
    358376}
    359377
    360 
    361 RTDECL(void) RTSemEventMultiSetSignaller(RTSEMEVENTMULTI hEventMultiSem, RTTHREAD hThread)
    362 {
    363     /** @todo implement RTSemEventMultiSetSignaller on OS/2 */
    364 }
    365 
    366 
    367 RTDECL(void) RTSemEventMultiAddSignaller(RTSEMEVENTMULTI hEventMultiSem, RTTHREAD hThread)
    368 {
    369 }
    370 
    371 
    372 RTDECL(void) RTSemEventMultiRemoveSignaller(RTSEMEVENTMULTI hEventMultiSem, RTTHREAD hThread)
    373 {
    374 }
    375 
  • trunk/src/VBox/Runtime/r3/posix/semmutex-posix.cpp

    r25711 r25721  
    127127
    128128
    129 RTDECL(int)  RTSemMutexDestroy(RTSEMMUTEX MutexSem)
     129RTDECL(int)  RTSemMutexDestroy(RTSEMMUTEX hMutexSem)
    130130{
    131131    /*
    132132     * Validate input.
    133133     */
    134     if (MutexSem == NIL_RTSEMMUTEX)
     134    if (hMutexSem == NIL_RTSEMMUTEX)
    135135        return VINF_SUCCESS;
    136     struct RTSEMMUTEXINTERNAL *pThis = MutexSem;
     136    struct RTSEMMUTEXINTERNAL *pThis = hMutexSem;
    137137    AssertPtrReturn(pThis, VERR_INVALID_HANDLE);
    138138    AssertReturn(pThis->u32Magic == RTSEMMUTEX_MAGIC, VERR_INVALID_HANDLE);
     
    144144    if (rc)
    145145    {
    146         AssertMsgFailed(("Failed to destroy mutex sem %p, rc=%d.\n", MutexSem, rc));
     146        AssertMsgFailed(("Failed to destroy mutex sem %p, rc=%d.\n", hMutexSem, rc));
    147147        return RTErrConvertFromErrno(rc);
    148148    }
     
    180180
    181181
    182 DECL_FORCE_INLINE(int) rtSemMutexRequest(RTSEMMUTEX MutexSem, unsigned cMillies, PCRTLOCKVALSRCPOS pSrcPos)
     182DECL_FORCE_INLINE(int) rtSemMutexRequest(RTSEMMUTEX hMutexSem, unsigned cMillies, PCRTLOCKVALSRCPOS pSrcPos)
    183183{
    184184    /*
    185185     * Validate input.
    186186     */
    187     struct RTSEMMUTEXINTERNAL *pThis = MutexSem;
     187    struct RTSEMMUTEXINTERNAL *pThis = hMutexSem;
    188188    AssertPtrReturn(pThis, VERR_INVALID_HANDLE);
    189189    AssertReturn(pThis->u32Magic == RTSEMMUTEX_MAGIC, VERR_INVALID_HANDLE);
     
    230230        if (rc)
    231231        {
    232             AssertMsgFailed(("Failed to lock mutex sem %p, rc=%d.\n", MutexSem, rc)); NOREF(rc);
     232            AssertMsgFailed(("Failed to lock mutex sem %p, rc=%d.\n", hMutexSem, rc)); NOREF(rc);
    233233            return RTErrConvertFromErrno(rc);
    234234        }
     
    261261        if (rc)
    262262        {
    263             AssertMsg(rc == ETIMEDOUT, ("Failed to lock mutex sem %p, rc=%d.\n", MutexSem, rc)); NOREF(rc);
     263            AssertMsg(rc == ETIMEDOUT, ("Failed to lock mutex sem %p, rc=%d.\n", hMutexSem, rc)); NOREF(rc);
    264264            return RTErrConvertFromErrno(rc);
    265265        }
     
    281281
    282282#undef RTSemMutexRequest
    283 RTDECL(int) RTSemMutexRequest(RTSEMMUTEX MutexSem, unsigned cMillies)
     283RTDECL(int) RTSemMutexRequest(RTSEMMUTEX hMutexSem, unsigned cMillies)
    284284{
    285285#ifndef RTSEMMUTEX_STRICT
    286     return rtSemMutexRequest(MutexSem, cMillies, NULL);
     286    return rtSemMutexRequest(hMutexSem, cMillies, NULL);
    287287#else
    288288    RTLOCKVALSRCPOS SrcPos = RTLOCKVALSRCPOS_INIT_NORMAL_API();
    289     return rtSemMutexRequest(MutexSem, cMillies, &SrcPos);
    290 #endif
    291 }
    292 
    293 
    294 RTDECL(int) RTSemMutexRequestDebug(RTSEMMUTEX MutexSem, unsigned cMillies, RTHCUINTPTR uId, RT_SRC_POS_DECL)
     289    return rtSemMutexRequest(hMutexSem, cMillies, &SrcPos);
     290#endif
     291}
     292
     293
     294RTDECL(int) RTSemMutexRequestDebug(RTSEMMUTEX hMutexSem, unsigned cMillies, RTHCUINTPTR uId, RT_SRC_POS_DECL)
    295295{
    296296    RTLOCKVALSRCPOS SrcPos = RTLOCKVALSRCPOS_INIT_DEBUG_API();
    297     return rtSemMutexRequest(MutexSem, cMillies, &SrcPos);
     297    return rtSemMutexRequest(hMutexSem, cMillies, &SrcPos);
    298298}
    299299
    300300
    301301#undef RTSemMutexRequestNoResume
    302 RTDECL(int) RTSemMutexRequestNoResume(RTSEMMUTEX MutexSem, unsigned cMillies)
     302RTDECL(int) RTSemMutexRequestNoResume(RTSEMMUTEX hMutexSem, unsigned cMillies)
    303303{
    304304    /* (EINTR isn't returned by the wait functions we're using.) */
    305305#ifndef RTSEMMUTEX_STRICT
    306     return rtSemMutexRequest(MutexSem, cMillies, NULL);
     306    return rtSemMutexRequest(hMutexSem, cMillies, NULL);
    307307#else
    308308    RTLOCKVALSRCPOS SrcPos = RTLOCKVALSRCPOS_INIT_NORMAL_API();
    309     return rtSemMutexRequest(MutexSem, cMillies, &SrcPos);
    310 #endif
    311 }
    312 
    313 
    314 RTDECL(int) RTSemMutexRequestNoResumeDebug(RTSEMMUTEX MutexSem, unsigned cMillies, RTHCUINTPTR uId, RT_SRC_POS_DECL)
     309    return rtSemMutexRequest(hMutexSem, cMillies, &SrcPos);
     310#endif
     311}
     312
     313
     314RTDECL(int) RTSemMutexRequestNoResumeDebug(RTSEMMUTEX hMutexSem, unsigned cMillies, RTHCUINTPTR uId, RT_SRC_POS_DECL)
    315315{
    316316    RTLOCKVALSRCPOS SrcPos = RTLOCKVALSRCPOS_INIT_DEBUG_API();
    317     return rtSemMutexRequest(MutexSem, cMillies, &SrcPos);
    318 }
    319 
    320 
    321 RTDECL(int)  RTSemMutexRelease(RTSEMMUTEX MutexSem)
     317    return rtSemMutexRequest(hMutexSem, cMillies, &SrcPos);
     318}
     319
     320
     321RTDECL(int)  RTSemMutexRelease(RTSEMMUTEX hMutexSem)
    322322{
    323323    /*
    324324     * Validate input.
    325325     */
    326     struct RTSEMMUTEXINTERNAL *pThis = MutexSem;
     326    struct RTSEMMUTEXINTERNAL *pThis = hMutexSem;
    327327    AssertPtrReturn(pThis, VERR_INVALID_HANDLE);
    328328    AssertReturn(pThis->u32Magic == RTSEMMUTEX_MAGIC, VERR_INVALID_HANDLE);
     
    367367    if (RT_UNLIKELY(rc))
    368368    {
    369         AssertMsgFailed(("Failed to unlock mutex sem %p, rc=%d.\n", MutexSem, rc)); NOREF(rc);
     369        AssertMsgFailed(("Failed to unlock mutex sem %p, rc=%d.\n", hMutexSem, rc)); NOREF(rc);
    370370        return RTErrConvertFromErrno(rc);
    371371    }
     
    375375
    376376
    377 RTDECL(bool) RTSemMutexIsOwned(RTSEMMUTEX hMutex)
     377RTDECL(bool) RTSemMutexIsOwned(RTSEMMUTEX hMutexSem)
    378378{
    379379    /*
    380380     * Validate.
    381381     */
    382     RTSEMMUTEXINTERNAL *pThis = hMutex;
     382    RTSEMMUTEXINTERNAL *pThis = hMutexSem;
    383383    AssertPtrReturn(pThis, false);
    384384    AssertReturn(pThis->u32Magic == RTSEMMUTEX_MAGIC, false);
  • trunk/src/VBox/Runtime/r3/win/semmutex-win.cpp

    r25711 r25721  
    116116
    117117
    118 RTDECL(int)  RTSemMutexDestroy(RTSEMMUTEX MutexSem)
    119 {
    120     /*
    121      * Validate.
    122      */
    123     RTSEMMUTEXINTERNAL *pThis = MutexSem;
     118RTDECL(int)  RTSemMutexDestroy(RTSEMMUTEX hMutexSem)
     119{
     120    /*
     121     * Validate.
     122     */
     123    RTSEMMUTEXINTERNAL *pThis = hMutexSem;
    124124    if (pThis == NIL_RTSEMMUTEX)
    125125        return VINF_SUCCESS;
     
    170170 *
    171171 * @returns Same as RTSEmMutexRequestNoResume
    172  * @param   MutexSem            The mutex handle.
     172 * @param   hMutexSem            The mutex handle.
    173173 * @param   cMillies            The number of milliseconds to wait.
    174174 * @param   pSrcPos             The source position of the caller.
    175175 */
    176 DECL_FORCE_INLINE(int) rtSemMutexRequestNoResume(RTSEMMUTEX MutexSem, unsigned cMillies, PCRTLOCKVALSRCPOS pSrcPos)
    177 {
    178     /*
    179      * Validate.
    180      */
    181     RTSEMMUTEXINTERNAL *pThis = MutexSem;
     176DECL_FORCE_INLINE(int) rtSemMutexRequestNoResume(RTSEMMUTEX hMutexSem, unsigned cMillies, PCRTLOCKVALSRCPOS pSrcPos)
     177{
     178    /*
     179     * Validate.
     180     */
     181    RTSEMMUTEXINTERNAL *pThis = hMutexSem;
    182182    AssertPtrReturn(pThis, VERR_INVALID_HANDLE);
    183183    AssertReturn(pThis->u32Magic == RTSEMMUTEX_MAGIC, VERR_INVALID_HANDLE);
     
    239239        {
    240240            int rc2 = RTErrConvertFromWin32(GetLastError());
    241             AssertMsgFailed(("Wait on MutexSem %p failed, rc=%d lasterr=%d\n", MutexSem, rc, GetLastError()));
     241            AssertMsgFailed(("Wait on hMutexSem %p failed, rc=%d lasterr=%d\n", hMutexSem, rc, GetLastError()));
    242242            if (rc2 != VINF_SUCCESS)
    243243                return rc2;
     
    251251
    252252#undef RTSemMutexRequestNoResume
    253 RTDECL(int) RTSemMutexRequestNoResume(RTSEMMUTEX MutexSem, unsigned cMillies)
     253RTDECL(int) RTSemMutexRequestNoResume(RTSEMMUTEX hMutexSem, unsigned cMillies)
    254254{
    255255#ifndef RTSEMMUTEX_STRICT
    256     return rtSemMutexRequestNoResume(MutexSem, cMillies, NULL);
     256    return rtSemMutexRequestNoResume(hMutexSem, cMillies, NULL);
    257257#else
    258258    RTLOCKVALSRCPOS SrcPos = RTLOCKVALSRCPOS_INIT_NORMAL_API();
    259     return rtSemMutexRequestNoResume(MutexSem, cMillies, &SrcPos);
    260 #endif
    261 }
    262 
    263 
    264 RTDECL(int) RTSemMutexRequestNoResumeDebug(RTSEMMUTEX MutexSem, unsigned cMillies, RTHCUINTPTR uId, RT_SRC_POS_DECL)
     259    return rtSemMutexRequestNoResume(hMutexSem, cMillies, &SrcPos);
     260#endif
     261}
     262
     263
     264RTDECL(int) RTSemMutexRequestNoResumeDebug(RTSEMMUTEX hMutexSem, unsigned cMillies, RTHCUINTPTR uId, RT_SRC_POS_DECL)
    265265{
    266266    RTLOCKVALSRCPOS SrcPos = RTLOCKVALSRCPOS_INIT_DEBUG_API();
    267     return rtSemMutexRequestNoResume(MutexSem, cMillies, &SrcPos);
    268 }
    269 
    270 
    271 RTDECL(int) RTSemMutexRelease(RTSEMMUTEX MutexSem)
    272 {
    273     /*
    274      * Validate.
    275      */
    276     RTSEMMUTEXINTERNAL *pThis = MutexSem;
     267    return rtSemMutexRequestNoResume(hMutexSem, cMillies, &SrcPos);
     268}
     269
     270
     271RTDECL(int) RTSemMutexRelease(RTSEMMUTEX hMutexSem)
     272{
     273    /*
     274     * Validate.
     275     */
     276    RTSEMMUTEXINTERNAL *pThis = hMutexSem;
    277277    AssertPtrReturn(pThis, VERR_INVALID_HANDLE);
    278278    AssertReturn(pThis->u32Magic == RTSEMMUTEX_MAGIC, VERR_INVALID_HANDLE);
     
    321321
    322322
    323 RTDECL(bool) RTSemMutexIsOwned(RTSEMMUTEX hMutex)
    324 {
    325     /*
    326      * Validate.
    327      */
    328     RTSEMMUTEXINTERNAL *pThis = hMutex;
     323RTDECL(bool) RTSemMutexIsOwned(RTSEMMUTEX hMutexSem)
     324{
     325    /*
     326     * Validate.
     327     */
     328    RTSEMMUTEXINTERNAL *pThis = hMutexSem;
    329329    AssertPtrReturn(pThis, false);
    330330    AssertReturn(pThis->u32Magic == RTSEMMUTEX_MAGIC, false);
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