Title: [183608] trunk/Source/WTF
- Revision
- 183608
- Author
- [email protected]
- Date
- 2015-04-29 20:05:37 -0700 (Wed, 29 Apr 2015)
Log Message
LazyNeverDestroyed is not thread safe in debug builds, causing assertions
https://bugs.webkit.org/show_bug.cgi?id=144378
Reviewed by Darin Adler.
* wtf/NeverDestroyed.h:
Modified Paths
Diff
Modified: trunk/Source/WTF/ChangeLog (183607 => 183608)
--- trunk/Source/WTF/ChangeLog 2015-04-30 03:03:57 UTC (rev 183607)
+++ trunk/Source/WTF/ChangeLog 2015-04-30 03:05:37 UTC (rev 183608)
@@ -1,3 +1,12 @@
+2015-04-29 Alexey Proskuryakov <[email protected]>
+
+ LazyNeverDestroyed is not thread safe in debug builds, causing assertions
+ https://bugs.webkit.org/show_bug.cgi?id=144378
+
+ Reviewed by Darin Adler.
+
+ * wtf/NeverDestroyed.h:
+
2015-04-28 Geoffrey Garen <[email protected]>
It shouldn't take 1846 lines of code and 5 FIXMEs to sort an array.
Modified: trunk/Source/WTF/wtf/NeverDestroyed.h (183607 => 183608)
--- trunk/Source/WTF/wtf/NeverDestroyed.h 2015-04-30 03:03:57 UTC (rev 183607)
+++ trunk/Source/WTF/wtf/NeverDestroyed.h 2015-04-30 03:05:37 UTC (rev 183608)
@@ -116,7 +116,9 @@
};
#if !ASSERT_DISABLED
- bool m_isConstructed = false;
+ // LazyNeverDestroyed objects are always static, so this variable is initialized to false.
+ // It must not be initialized dynamically, because that would not be thread safe.
+ bool m_isConstructed;
#endif
};
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes