Bug 264799

Summary: [MSE] SourceBufferPrivate::didUpdateFormatDescriptionForTrackId can run out of order.
Product: WebKit Reporter: Jean-Yves Avenard [:jya] <jean-yves.avenard>
Component: MediaAssignee: Jean-Yves Avenard [:jya] <jean-yves.avenard>
Status: RESOLVED FIXED    
Severity: Normal CC: webkit-bug-importer
Priority: P2 Keywords: InRadar
Version: WebKit Nightly Build   
Hardware: Unspecified   
OS: Unspecified   
Bug Depends on: 253789    
Bug Blocks:    

Description Jean-Yves Avenard [:jya] 2023-11-14 00:38:22 PST
In bug 253789, didUpdateFormatDescriptionForTrackId was added as a callback to the SourceBufferParser .

However, processing the TrackInfo, which should always be after we've parsed the initialisation segment can actually before as it's not added to the SourceBufferPrivate::operationQueue but instead is run immediately.

If it happens that the initialisation segment hasn't been parsed yet, we end up disabling the track instead.
Comment 1 Radar WebKit Bug Importer 2023-11-14 00:39:03 PST
<rdar://problem/118380017>
Comment 2 Jean-Yves Avenard [:jya] 2023-11-14 00:49:26 PST
Pull request: https://github.com/WebKit/WebKit/pull/20469
Comment 3 Jean-Yves Avenard [:jya] 2023-11-14 03:15:33 PST
Pull request: https://github.com/WebKit/WebKit/pull/19765
Comment 4 EWS 2023-11-14 03:52:15 PST
Committed 270703@main (49ba5f074748): <https://commits.webkit.org/270703@main>

Reviewed commits have been landed. Closing PR #20469 and removing active labels.