WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
211980
[GStreamer][MediaStream] Remove orphaned tracks in updateTracks()
https://bugs.webkit.org/show_bug.cgi?id=211980
Summary
[GStreamer][MediaStream] Remove orphaned tracks in updateTracks()
Alicia Boya García
Reported
2020-05-16 03:01:25 PDT
This patch ensures tracks missing from a subsequent updateTracks() calls are removed from the player. This fixes the following tests regressed by the track switch rework: imported/w3c/web-platform-tests/mediacapture-streams/MediaStream-removetrack.https.html imported/w3c/web-platform-tests/mediacapture-streams/MediaStreamTrack-applyConstraints.https.html
Attachments
Patch
(6.58 KB, patch)
2020-05-16 05:26 PDT
,
Alicia Boya García
no flags
Details
Formatted Diff
Diff
Patch
(6.63 KB, patch)
2020-05-16 09:17 PDT
,
Alicia Boya García
no flags
Details
Formatted Diff
Diff
Show Obsolete
(1)
View All
Add attachment
proposed patch, testcase, etc.
Alicia Boya García
Comment 1
2020-05-16 05:26:31 PDT
Created
attachment 399548
[details]
Patch
Alicia Boya García
Comment 2
2020-05-16 09:17:18 PDT
Created
attachment 399555
[details]
Patch
Philippe Normand
Comment 3
2020-05-18 01:15:46 PDT
Comment on
attachment 399555
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=399555&action=review
> Source/WebCore/platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:1512 > +template<typename K, typename V> > +HashSet<K> hashSetFromHashMapKeys(const HashMap<K, V>& hashMap) > +{ > + HashSet<K> keys; > + for (auto& key : hashMap.keys()) > + keys.add(key); > + return keys; > +}
Would this be worth moving to HashMap as a new method?
Alicia Boya García
Comment 4
2020-05-18 01:52:04 PDT
Comment on
attachment 399555
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=399555&action=review
>> Source/WebCore/platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:1512 >> +} > > Would this be worth moving to HashMap as a new method?
I don't know, all HashMap methods are pretty basic, so maybe someone would oppose this in WTF, or maybe a function already exists and I just didn't find it. I wanted a self-contained fix that didn't need a potentially stalling WTF review, so this was a reasonable solution. I've asked in the WebKit slack, if it turns out there was an existing function or there wasn't but people really want it in WTF another patch can be made that moves it there. For now I'm using this.
EWS
Comment 5
2020-05-18 02:09:34 PDT
Committed
r261803
: <
https://trac.webkit.org/changeset/261803
> All reviewed patches have been landed. Closing bug and clearing flags on
attachment 399555
[details]
.
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug