[JSC] FunctionOverrides should have a lock to ensure concurrent access to hash table...
[WebKit-https.git] / Source / JavaScriptCore / tools / FunctionOverrides.h
index 4a42bbc..8829670 100644 (file)
@@ -27,6 +27,7 @@
 
 #include "SourceCode.h"
 #include <wtf/HashMap.h>
+#include <wtf/Lock.h>
 #include <wtf/text/WTFString.h>
 
 namespace JSC {
@@ -56,10 +57,11 @@ public:
     JS_EXPORT_PRIVATE static void reinstallOverrides();
 
 private:
-    void parseOverridesInFile(const char* fileName);
-    void clear() { m_entries.clear(); }
+    void parseOverridesInFile(const AbstractLocker&, const char* fileName);
+    void clear(const AbstractLocker&) { m_entries.clear(); }
 
     HashMap<String, String> m_entries;
+    Lock m_lock;
 };
 
 } // namespace JSC