Don't try to loop if current time or duration is zero
<rdar://problem/118902468>
Pull request: https://github.com/WebKit/WebKit/pull/21025
Committed 271256@main (9ebaa6b42015): <https://commits.webkit.org/271256@main> Reviewed commits have been landed. Closing PR #21025 and removing active labels.