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

Side by Side Diff: content/child/quota_message_filter.cc

Issue 1154283003: Change most uses of Pickle to base::Pickle (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 6 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 unified diff | Download patch
« no previous file with comments | « content/child/push_messaging/push_dispatcher.cc ('k') | content/child/resource_dispatcher.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "content/child/quota_message_filter.h" 5 #include "content/child/quota_message_filter.h"
6 6
7 #include "content/child/quota_dispatcher.h" 7 #include "content/child/quota_dispatcher.h"
8 #include "content/common/quota_messages.h" 8 #include "content/common/quota_messages.h"
9 9
10 namespace content { 10 namespace content {
(...skipping 26 matching lines...) Expand all
37 } 37 }
38 38
39 void QuotaMessageFilter::OnFilteredMessageReceived(const IPC::Message& msg) { 39 void QuotaMessageFilter::OnFilteredMessageReceived(const IPC::Message& msg) {
40 QuotaDispatcher::ThreadSpecificInstance(thread_safe_sender(), this) 40 QuotaDispatcher::ThreadSpecificInstance(thread_safe_sender(), this)
41 ->OnMessageReceived(msg); 41 ->OnMessageReceived(msg);
42 } 42 }
43 43
44 bool QuotaMessageFilter::GetWorkerThreadIdForMessage(const IPC::Message& msg, 44 bool QuotaMessageFilter::GetWorkerThreadIdForMessage(const IPC::Message& msg,
45 int* ipc_thread_id) { 45 int* ipc_thread_id) {
46 int request_id = -1; 46 int request_id = -1;
47 const bool success = PickleIterator(msg).ReadInt(&request_id); 47 const bool success = base::PickleIterator(msg).ReadInt(&request_id);
48 DCHECK(success); 48 DCHECK(success);
49 49
50 base::AutoLock lock(request_id_map_lock_); 50 base::AutoLock lock(request_id_map_lock_);
51 RequestIdToThreadId::iterator found = request_id_map_.find(request_id); 51 RequestIdToThreadId::iterator found = request_id_map_.find(request_id);
52 if (found != request_id_map_.end()) { 52 if (found != request_id_map_.end()) {
53 *ipc_thread_id = found->second; 53 *ipc_thread_id = found->second;
54 request_id_map_.erase(found); 54 request_id_map_.erase(found);
55 return true; 55 return true;
56 } 56 }
57 return false; 57 return false;
58 } 58 }
59 59
60 } // namespace content 60 } // namespace content
OLDNEW
« no previous file with comments | « content/child/push_messaging/push_dispatcher.cc ('k') | content/child/resource_dispatcher.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698