DescriptionFix --trace-shutdown with thread-local tracing.
With thread-local tracing (r221766), TraceLog::Flush() is async and
needs to be called from a thread having a message loop. It also requires
that tracing has been stopped.
BrowserShutdownProfileDumper is a special caller that TraceLog::Flush()
was originally called from a thread without message loop.
Now start another thread for flushing, and call TraceLog::SetDisabled()
before TraceLog::Flush().
The calling thread needs to wait for the completion of the flush,
otherwise the browser may shutdown before all trace events written.
Temporarily allow the thread to wait in ThreadRestrictions.
BUG=none
TEST=manual run chrome with --trace-shutdown. Should not assert. Should generate correct trace file.
Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=223819
Patch Set 1 #
Messages
Total messages: 10 (0 generated)
|