Skip to content
This repository was archived by the owner on Apr 23, 2020. It is now read-only.

Commit ab4302d

Browse files
committed
[libcxxabi] __cxa_guard_require: test guard byte with != 0 instead of == 1
git-svn-id: https://llvm.org/svn/llvm-project/libcxxabi/trunk@369109 91177308-0d34-0410-b5e6-96231b3b80d8
1 parent f3b4aeb commit ab4302d

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/cxa_guard_impl.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -175,7 +175,7 @@ struct GuardObject {
175175
/// Implements __cxa_guard_acquire
176176
AcquireResult cxa_guard_acquire() {
177177
AtomicInt<uint8_t> guard_byte(guard_byte_address);
178-
if (guard_byte.load(std::_AO_Acquire) == COMPLETE_BIT)
178+
if (guard_byte.load(std::_AO_Acquire) != UNSET)
179179
return INIT_IS_DONE;
180180
return derived()->acquire_init_byte();
181181
}

0 commit comments

Comments
 (0)