The InspectorTimelineAgent should gracefully handle attempts to start more than once.
authormark.lam@apple.com <mark.lam@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 2 Mar 2015 23:39:47 +0000 (23:39 +0000)
committermark.lam@apple.com <mark.lam@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 2 Mar 2015 23:39:47 +0000 (23:39 +0000)
commit7239cc02440c5978c8f4057b67bd83dc20a27b5c
tree7484c60481758660ce10f04adcb19ea2633a261d
parente86112fdc379bfb9cbbe9dab53eaeb690c70e740
The InspectorTimelineAgent should gracefully handle attempts to start more than once.
<https://webkit.org/b/142189>

Reviewed by Joseph Pecoraro.

Source/WebCore:

No new tests.  Unskipped an existing test that already asserts this.

InspectorTimelineAgent::internalStop() already checks for redundant calls to it in
case the InspectorTimelineAgent is already disabled. Similarly,
InspectorTimelineAgent::internalStart() should check if the InspectorTimelineAgent
is already enabled before proceeding to do work to enable it. Though wasteful,
it is legal for clients of the InspectorTimelineAgent to invoke start on it more
than once. Hence, this check is needed.

This check fixes the debug assertion failure when running the
inspector/timeline/debugger-paused-while-recording.html test. The test can now
be unskipped.

* inspector/InspectorTimelineAgent.cpp:
(WebCore::InspectorTimelineAgent::internalStart):

LayoutTests:

* TestExpectations:
- Unskipped inspector/timeline tests.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@180901 268f45cc-cd09-0410-ab3c-d52691b4dbfc
LayoutTests/ChangeLog
LayoutTests/TestExpectations
Source/WebCore/ChangeLog
Source/WebCore/inspector/InspectorTimelineAgent.cpp