| Index: content/renderer/renderer_main.cc
|
| ===================================================================
|
| --- content/renderer/renderer_main.cc (revision 148974)
|
| +++ content/renderer/renderer_main.cc (working copy)
|
| @@ -70,45 +70,6 @@
|
|
|
| #endif // OS_MACOSX
|
|
|
| -#if defined(OS_POSIX)
|
| -
|
| -class SuicideOnChannelErrorFilter : public IPC::ChannelProxy::MessageFilter {
|
| - public:
|
| - // IPC::ChannelProxy::MessageFilter
|
| - virtual void OnChannelError() OVERRIDE {
|
| - // On POSIX, at least, one can install an unload handler which loops
|
| - // forever and leave behind a renderer process which eats 100% CPU forever.
|
| - //
|
| - // This is because the terminate signals (ViewMsg_ShouldClose and the error
|
| - // from the IPC channel) are routed to the main message loop but never
|
| - // processed (because that message loop is stuck in V8).
|
| - //
|
| - // One could make the browser SIGKILL the renderers, but that leaves open a
|
| - // large window where a browser failure (or a user, manually terminating
|
| - // the browser because "it's stuck") will leave behind a process eating all
|
| - // the CPU.
|
| - //
|
| - // So, we install a filter on the channel so that we can process this event
|
| - // here and kill the process.
|
| - //
|
| - // We want to kill this process after giving it 30 seconds to run the exit
|
| - // handlers. SIGALRM has a default disposition of terminating the
|
| - // application.
|
| -#if defined(OS_POSIX)
|
| - if (CommandLine::ForCurrentProcess()->
|
| - HasSwitch(switches::kRendererCleanExit))
|
| - alarm(30);
|
| - else
|
| -#endif
|
| - _exit(0);
|
| - }
|
| -
|
| - protected:
|
| - virtual ~SuicideOnChannelErrorFilter() {}
|
| -};
|
| -
|
| -#endif // OS(POSIX)
|
| -
|
| } // namespace
|
|
|
| // This function provides some ways to test crash and assertion handling
|
| @@ -246,10 +207,6 @@
|
| new RenderThreadImpl();
|
| #endif
|
|
|
| -#if defined(OS_POSIX)
|
| - RenderThreadImpl::current()->AddFilter(new SuicideOnChannelErrorFilter());
|
| -#endif
|
| -
|
| platform.RunSandboxTests();
|
|
|
| startup_timer.Stop(); // End of Startup Time Measurement.
|
|
|