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

Unified Diff: content/common/child_thread.cc

Issue 7888024: Move handle dumpage to the renderer process (so that it works correctly) and factor out redundant... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 9 years, 3 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 | « content/common/child_thread.h ('k') | content/common/content_switches.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/common/child_thread.cc
===================================================================
--- content/common/child_thread.cc (revision 101774)
+++ content/common/child_thread.cc (working copy)
@@ -22,6 +22,10 @@
#include "ipc/ipc_switches.h"
#include "webkit/glue/webkit_glue.h"
+#if defined(OS_WIN)
+#include "content/common/handle_enumerator_win.h"
+#endif
+
ChildThread::ChildThread() {
channel_name_ = CommandLine::ForCurrentProcess()->GetSwitchValueASCII(
switches::kProcessChannelID);
@@ -158,6 +162,7 @@
IPC_MESSAGE_HANDLER(ChildProcessMsg_SetIPCLoggingEnabled,
OnSetIPCLoggingEnabled)
#endif
+ IPC_MESSAGE_HANDLER(ChildProcessMsg_DumpHandles, OnDumpHandles)
IPC_MESSAGE_UNHANDLED(handled = false)
IPC_END_MESSAGE_MAP()
@@ -191,6 +196,20 @@
}
#endif // IPC_MESSAGE_LOG_ENABLED
+void ChildThread::OnDumpHandles() {
+#if defined(OS_WIN)
+ scoped_refptr<content::HandleEnumerator> handle_enum(
+ new content::HandleEnumerator(
+ CommandLine::ForCurrentProcess()->HasSwitch(
+ switches::kAuditAllHandles)));
+ handle_enum->EnumerateHandles();
+ Send(new ChildProcessHostMsg_DumpHandlesDone);
+ return;
+#endif
+
+ NOTIMPLEMENTED();
+}
+
ChildThread* ChildThread::current() {
return ChildProcess::current()->main_thread();
}
« no previous file with comments | « content/common/child_thread.h ('k') | content/common/content_switches.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698