WebKit Bugzilla
New
Browse
Search+
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED DUPLICATE of
bug 295888
295887
(iOS) getUserMedia() incorrectly emit 'devicechange' listener
https://bugs.webkit.org/show_bug.cgi?id=295887
Summary
(iOS) getUserMedia() incorrectly emit 'devicechange' listener
Ronan Chi
Reported
2025-07-14 06:51:46 PDT
When I test getUserMedia() API in iOS, it incorrectly emit 'devicechange' listener. And I call getUserMedia() again in my web app, it will cause <strong>infinite</strong> 'devicechange' listener loop. It's ok in Chrome or PC Browser. Online Link:
https://bug.qer.im/ios-getUserMedia-incorrectly-emit-devicechange-listener/index.html
```js navigator.mediaDevices.addEventListener('devicechange', () => { requestDevice(); }); async function requestDevice() { log('log', 'getUserMedia'); const stream = await navigator.mediaDevices.getUserMedia({ audio: true }); stream.getTracks().forEach(track => { track.stop(); }); } requestDevice(); ```
Attachments
Add attachment
proposed patch, testcase, etc.
Ronan Chi
Comment 1
2025-07-14 06:55:35 PDT
*** This bug has been marked as a duplicate of
bug 295888
***
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