| Index: Source/platform/heap/SafePoint.h
|
| diff --git a/Source/platform/heap/SafePoint.h b/Source/platform/heap/SafePoint.h
|
| index 76713c4c9cf6fcf91b7bcb568bfadc520a6580ea..29d248a99d65534a27f80f70259a098e646e8be6 100644
|
| --- a/Source/platform/heap/SafePoint.h
|
| +++ b/Source/platform/heap/SafePoint.h
|
| @@ -13,8 +13,8 @@ namespace blink {
|
| class SafePointScope final {
|
| WTF_MAKE_NONCOPYABLE(SafePointScope);
|
| public:
|
| - explicit SafePointScope(ThreadState::StackState stackState)
|
| - : m_state(ThreadState::current())
|
| + SafePointScope(ThreadState::StackState stackState, ThreadState* state = ThreadState::current())
|
| + : m_state(state)
|
| {
|
| RELEASE_ASSERT(!m_state->isAtSafePoint());
|
| m_state->enterSafePoint(stackState, this);
|
| @@ -22,8 +22,7 @@ public:
|
|
|
| ~SafePointScope()
|
| {
|
| - if (m_state)
|
| - m_state->leaveSafePoint();
|
| + m_state->leaveSafePoint();
|
| }
|
|
|
| private:
|
|
|