Fix media never requested again when changing again to current device
When the MediaDevicesSource node is active and a media device changes
the current stream is replaced by a stream from the new selected device.
This is an asynchronous operation, so changing the stream again on
further device changes is deferred until the previous one finished.
However, when the changed device was the same as the current device
(which should not happen, although it could potentially happen with a
specific sequence of "devicechange" events emitted by the browser) the
pending request count was not cleared and thus any further device change
was ignored until the page was reloaded.
Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
Loading
Please register or sign in to comment