The fullscreen video layer's WebAVPlayerController is retained by the player view controller and can outlive the layer, so clear the view controller's delegate and player controller when we exit from fullscreen.
Created attachment 227502 [details] Proposed patch.
<rdar://problem/16396567>
<rdar://problem/16396588>
Comment on attachment 227502 [details] Proposed patch. View in context: https://bugs.webkit.org/attachment.cgi?id=227502&action=review r=me with nits. > Source/WebCore/platform/ios/WebVideoFullscreenInterfaceAVKit.mm:207 > + if (_avPlayerController && [_avPlayerController delegate]) This should be unnecessary. If _avPlayerController is nil, [_avPlayerController delegate] will return nil as well. > Source/WebCore/platform/ios/WebVideoFullscreenInterfaceAVKit.mm:215 > + if (!_avPlayerController || ![_avPlayerController delegate]) Ditto.
Committed r166106: https://trac.webkit.org/r166106