iOS AVPlayerItem 视频无法播放解决办法 Code=-11850 Code=-12939 Operation Stopped The server is not correctly configured

这个问题的表现为,AVPlayerItem 开始播放的时候就失败了,Google 和 SOF 很久之后仍然没有答案,最终解决了。

错误示例:

Domain=AVFoundationErrorDomain Code=-11850 "Operation Stopped" UserInfo={NSUnderlyingError=0x7f927ede4210
{Error Domain=NSOSStatusErrorDomain Code=-12939 "(null)"}
, NSLocalizedFailureReason=The server is not correctly configured., NSLocalizedDescription=Operation Stopped})

总结一下,视频在最开始播放的时候,会请求一个 Range【0-1】 的 bytes range request。
如果返回 hTTP Code = 200,那么就报 11850 错误.
如果返回 206,那么正常播放。
11850 错误含义:The HTTP server sending the media resource is not configured as expected. This might mean that the server does not support byte range requests.

最后编辑于
©著作权归作者所有,转载或内容合作请联系作者
【社区内容提示】社区部分内容疑似由AI辅助生成,浏览时请结合常识与多方信息审慎甄别。
平台声明:文章内容(如有图片或视频亦包括在内)由作者上传并发布,文章内容仅代表作者本人观点,简书系信息发布平台,仅提供信息存储服务。

相关阅读更多精彩内容

友情链接更多精彩内容