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

Side by Side Diff: chrome/common/resource_dispatcher.h

Issue 115396: Fix a memory leak in ResourceDispatcher... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 11 years, 7 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 | Annotate | Revision Log
« no previous file with comments | « base/shared_memory_win.cc ('k') | chrome/common/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 (c) 2006-2008 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2006-2008 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 // See http://dev.chromium.org/developers/design-documents/multi-process-resourc e-loading 5 // See http://dev.chromium.org/developers/design-documents/multi-process-resourc e-loading
6 6
7 #ifndef CHROME_COMMON_RESOURCE_DISPATCHER_H__ 7 #ifndef CHROME_COMMON_RESOURCE_DISPATCHER_H__
8 #define CHROME_COMMON_RESOURCE_DISPATCHER_H__ 8 #define CHROME_COMMON_RESOURCE_DISPATCHER_H__
9 9
10 #include <deque> 10 #include <deque>
(...skipping 96 matching lines...) Expand 10 before | Expand all | Expand 10 after
107 // Dispatch the message to one of the message response handlers. 107 // Dispatch the message to one of the message response handlers.
108 void DispatchMessage(const IPC::Message& message); 108 void DispatchMessage(const IPC::Message& message);
109 109
110 // Dispatch any deferred messages for the given request, provided it is not 110 // Dispatch any deferred messages for the given request, provided it is not
111 // again in the deferred state. 111 // again in the deferred state.
112 void FlushDeferredMessages(int request_id); 112 void FlushDeferredMessages(int request_id);
113 113
114 // Returns true if the message passed in is a resource related message. 114 // Returns true if the message passed in is a resource related message.
115 static bool IsResourceDispatcherMessage(const IPC::Message& message); 115 static bool IsResourceDispatcherMessage(const IPC::Message& message);
116 116
117 // ViewHostMsg_Resource_DataReceived is not POD, it has a shared memory
118 // handle in it that we should cleanup it up nicely. This method accepts any
119 // message and determine whether the message is
120 // ViewHostMsg_Resource_DataReceived and clean up the shared memory handle.
121 void ReleaseResourcesInDataMessage(const IPC::Message& message);
122
117 IPC::Message::Sender* message_sender_; 123 IPC::Message::Sender* message_sender_;
118 124
119 // All pending requests issued to the host 125 // All pending requests issued to the host
120 PendingRequestList pending_requests_; 126 PendingRequestList pending_requests_;
121 127
122 ScopedRunnableMethodFactory<ResourceDispatcher> method_factory_; 128 ScopedRunnableMethodFactory<ResourceDispatcher> method_factory_;
123 129
124 DISALLOW_EVIL_CONSTRUCTORS(ResourceDispatcher); 130 DISALLOW_EVIL_CONSTRUCTORS(ResourceDispatcher);
125 }; 131 };
126 132
127 #endif // CHROME_COMMON_RESOURCE_DISPATCHER_H__ 133 #endif // CHROME_COMMON_RESOURCE_DISPATCHER_H__
OLDNEW
« no previous file with comments | « base/shared_memory_win.cc ('k') | chrome/common/resource_dispatcher.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698