Commit 3895dfe2 authored by thestig@chromium.org's avatar thestig@chromium.org

TSAN: Speculative fix for race errors in DeviceOrientationProviderTest.

BUG=139849
TEST=none

Review URL: https://chromiumcodereview.appspot.com/10846003

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@149276 0039d316-1c4b-4281-b951-d872f2087c98
parent e82ac463
...@@ -66,7 +66,8 @@ class UpdateChecker : public Provider::Observer { ...@@ -66,7 +66,8 @@ class UpdateChecker : public Provider::Observer {
}; };
// Class for injecting test orientation data into the Provider. // Class for injecting test orientation data into the Provider.
class MockOrientationFactory : public base::RefCounted<MockOrientationFactory> { class MockOrientationFactory
: public base::RefCountedThreadSafe<MockOrientationFactory> {
public: public:
MockOrientationFactory() MockOrientationFactory()
: is_failing_(false) { : is_failing_(false) {
...@@ -98,7 +99,7 @@ class MockOrientationFactory : public base::RefCounted<MockOrientationFactory> { ...@@ -98,7 +99,7 @@ class MockOrientationFactory : public base::RefCounted<MockOrientationFactory> {
} }
private: private:
friend class base::RefCounted<MockOrientationFactory>; friend class base::RefCountedThreadSafe<MockOrientationFactory>;
~MockOrientationFactory() { ~MockOrientationFactory() {
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment