Skip to content

Commit fd1cd16

Browse files
Ian Gilbertwebkit-commit-queue
authored andcommitted
[Web Animations] nullptr crash in updatePlaybackRate() with no timeline
https://bugs.webkit.org/show_bug.cgi?id=223095 Patch by Ian Gilbert <[email protected]> on 2021-03-22 Reviewed by Ryosuke Niwa. Changed to WebAnimation::remove() to use setTimeline() instead of setTimelineInternal() to ensure the animation is in the correct play state. No new tests as this relies on navigating while updating the playback rate and I was unable to make a reliable test case. * animation/WebAnimation.cpp: (WebCore::WebAnimation::remove): Changed setTimelineInternal() to setTimeline() in order to ensure the animation has the correct play state. Canonical link: https://commits.webkit.org/235621@main git-svn-id: https://svn.webkit.org/repository/webkit/trunk@274824 268f45cc-cd09-0410-ab3c-d52691b4dbfc
1 parent 8a957b2 commit fd1cd16

2 files changed

Lines changed: 18 additions & 1 deletion

File tree

Source/WebCore/ChangeLog

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,20 @@
1+
2021-03-22 Ian Gilbert <[email protected]>
2+
3+
[Web Animations] nullptr crash in updatePlaybackRate() with no timeline
4+
https://bugs.webkit.org/show_bug.cgi?id=223095
5+
6+
Reviewed by Ryosuke Niwa.
7+
8+
Changed to WebAnimation::remove() to use setTimeline() instead of setTimelineInternal()
9+
to ensure the animation is in the correct play state.
10+
11+
No new tests as this relies on navigating while updating the playback rate and I was unable to make
12+
a reliable test case.
13+
14+
* animation/WebAnimation.cpp:
15+
(WebCore::WebAnimation::remove): Changed setTimelineInternal() to setTimeline() in order to
16+
ensure the animation has the correct play state.
17+
118
2021-03-22 Patrick Angle <[email protected]>
219

320
Web Inspector: Port grid overlay drawing to iOS

Source/WebCore/animation/WebAnimation.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -120,7 +120,7 @@ void WebAnimation::remove()
120120
// This object could be deleted after either clearing the effect or timeline relationship.
121121
auto protectedThis = makeRef(*this);
122122
setEffectInternal(nullptr);
123-
setTimelineInternal(nullptr);
123+
setTimeline(nullptr);
124124
}
125125

126126
void WebAnimation::suspendEffectInvalidation()

0 commit comments

Comments
 (0)