Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(5364)

Unified Diff: chrome_frame/test/net/test_automation_resource_message_filter.h

Issue 9158012: Synchronize access to TestAutomationResourceMessageFilter's requests_ map. This fixes a race cond... (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: '' Created 8 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | chrome_frame/test/net/test_automation_resource_message_filter.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome_frame/test/net/test_automation_resource_message_filter.h
===================================================================
--- chrome_frame/test/net/test_automation_resource_message_filter.h (revision 116132)
+++ chrome_frame/test/net/test_automation_resource_message_filter.h (working copy)
@@ -1,9 +1,12 @@
-// Copyright (c) 2009 The Chromium Authors. All rights reserved.
+// Copyright (c) 2012 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#ifndef CHROME_FRAME_TEST_NET_TEST_AUTOMATION_RESOURCE_MESSAGE_FILTER_H_
#define CHROME_FRAME_TEST_NET_TEST_AUTOMATION_RESOURCE_MESSAGE_FILTER_H_
+#include <map>
+
+#include "base/synchronization/lock.h"
#include "chrome/browser/automation/automation_provider.h"
#include "chrome/browser/automation/automation_resource_message_filter.h"
#include "chrome/browser/automation/url_request_automation_job.h"
@@ -46,6 +49,9 @@
};
typedef std::map<int, RequestJob> RequestMap;
RequestMap requests_;
+
+ // Protects access to requests_.
+ base::Lock requests_lock_;
};
#endif // CHROME_FRAME_TEST_NET_TEST_AUTOMATION_RESOURCE_MESSAGE_FILTER_H_
« no previous file with comments | « no previous file | chrome_frame/test/net/test_automation_resource_message_filter.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698