Bug 257241
| Summary: | [Cocoa] Call [AVCaptureDevice ensureServerConnection] when new extensions are made to the GPU Process | ||
|---|---|---|---|
| Product: | WebKit | Reporter: | Brent Fulgham <bfulgham> |
| Component: | WebKit2 | Assignee: | Brent Fulgham <bfulgham> |
| Status: | RESOLVED FIXED | ||
| Severity: | Normal | CC: | kkinnunen, webkit-bug-importer |
| Priority: | P2 | Keywords: | InRadar |
| Version: | WebKit Nightly Build | ||
| Hardware: | Unspecified | ||
| OS: | Unspecified | ||
Brent Fulgham
Our current code only calls [AVCaptureDevice ensureServerConnection] the first time we extend the sandbox. This can lead to problems if the user visits a site that only needs Microphone access (for example), and then visits a site that needs Camera access. Because the camera-related extensions are only recognized by the video capture system when [AVCaptureDevice ensureServiceConnection] is called, the fact that we called it before the new sandbox extensions were in place mean we never activate the relevant features.
To fix this, we should simply call [AVCaptureDevice ensureServerConnection] any time we extend the sandbox. I have confirmed with the relevant teams that this call is low-cost (performance wise), and is not harmful to call repeatedly for things that have already been activated.
| Attachments | ||
|---|---|---|
| Add attachment proposed patch, testcase, etc. |
Brent Fulgham
<rdar://109380900>
Brent Fulgham
Pull request: https://github.com/WebKit/WebKit/pull/14276
EWS
Committed 264460@main (fe4af8b17fb6): <https://commits.webkit.org/264460@main>
Reviewed commits have been landed. Closing PR #14276 and removing active labels.