Fix typo in mutex.h file.
Change-Id: I11db56161025285022ea1137fb7749751d14b347
diff --git a/runtime/base/mutex.h b/runtime/base/mutex.h
index b924798..21ba0d2 100644
--- a/runtime/base/mutex.h
+++ b/runtime/base/mutex.h
@@ -238,7 +238,7 @@
// Assert the current thread has exclusive access to the ReaderWriterMutex.
void AssertExclusiveHeld(const Thread* self) {
- if (kDebugLocking & (gAborting == 0)) {
+ if (kDebugLocking && (gAborting == 0)) {
CHECK(IsExclusiveHeld(self)) << *this;
}
}
@@ -246,7 +246,7 @@
// Assert the current thread doesn't have exclusive access to the ReaderWriterMutex.
void AssertNotExclusiveHeld(const Thread* self) {
- if (kDebugLocking & (gAborting == 0)) {
+ if (kDebugLocking && (gAborting == 0)) {
CHECK(!IsExclusiveHeld(self)) << *this;
}
}
@@ -257,7 +257,7 @@
// Assert the current thread has shared access to the ReaderWriterMutex.
void AssertSharedHeld(const Thread* self) {
- if (kDebugLocking & (gAborting == 0)) {
+ if (kDebugLocking && (gAborting == 0)) {
// TODO: we can only assert this well when self != NULL.
CHECK(IsSharedHeld(self) || self == NULL) << *this;
}