Closed Bug 1727558 Opened 3 years ago Closed 3 years ago

Write a RAII class for Mutex::TryLock

Categories

(Core :: XPCOM, enhancement, P2)

enhancement

Tracking

()

RESOLVED FIXED
93 Branch
Tracking Status
firefox93 --- fixed

People

(Reporter: pehrsons, Assigned: pehrsons)

References

Details

Attachments

(2 files)

See D123225 for where this is useful.

TL;DR to avoid blocking the real-time audio thread while webrtc is doing renegotiation on another thread.

There is no risk of deadlock in TryLock(). Having this breaks the AutoTryLock
gtest.

Pushed by pehrsons@gmail.com:
https://hg.mozilla.org/integration/autoland/rev/73af56c459bd
Dont CheckAcquire() in debug version of OffTheBooksMutex::TryLock(). r=xpcom-reviewers,nika
https://hg.mozilla.org/integration/autoland/rev/b50a423ec975
Implement an RAII class for Mutex::TryLock. r=xpcom-reviewers,nika
Status: ASSIGNED → RESOLVED
Closed: 3 years ago
Resolution: --- → FIXED
Target Milestone: --- → 93 Branch
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: