Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: 16667e0251b6b7ed43163f936641ccb15d34cc9f
      
https://github.com/WebKit/WebKit/commit/16667e0251b6b7ed43163f936641ccb15d34cc9f
  Author: Jer Noble <[email protected]>
  Date:   2025-11-19 (Wed, 19 Nov 2025)

  Changed paths:
    A LayoutTests/media/track/track-with-no-src-loading-expected.txt
    A LayoutTests/media/track/track-with-no-src-loading.html
    M Source/WebCore/html/HTMLTrackElement.cpp

  Log Message:
  -----------
  Empty track elements can prevent media from loading & playing
rdar://164125914
https://bugs.webkit.org/show_bug.cgi?id=302828

Reviewed by Jean-Yves Avenard.

The HTML standard requires HTMLTrackElements with an empty trackURL to
generate an "error" event and move to the "ERROR" readyState/readiness
state. However, WebCore is returning early from the resource selection
algorithm when a HTMLTrackElement does not have a src attribute, which
causes the readyState to get stuck at Loading. Additionally, the media
element containing the track cannot progress its own readyState beyond
HAVE_CURRENT_DATA, which blocks play() commands from completing.

Remove the early return from HTMLTrackElement::scheduleLoad().

Test: media/track/track-with-no-src-loading.html

* LayoutTests/media/track/track-with-no-src-loading-expected.txt: Added.
* LayoutTests/media/track/track-with-no-src-loading.html: Added.
* Source/WebCore/html/HTMLTrackElement.cpp:
(WebCore::HTMLTrackElement::scheduleLoad):

Canonical link: https://commits.webkit.org/303314@main



To unsubscribe from these emails, change your notification settings at 
https://github.com/WebKit/WebKit/settings/notifications

Reply via email to