【问题标题】:MPMoviePlayerViewController work fine with debug but crash in release on iOS9MPMoviePlayerViewController 在调试时工作正常,但在 iOS9 上发布时崩溃
【发布时间】:2015-10-15 06:58:07
【问题描述】:

MPMoviePlayerViewController 在调试时工作正常,但在 iOS9 上发布时崩溃

MPMoviePlayerViewController *playerViewController = [[MPMoviePlayerViewController alloc] initWithContentURL:url];
self.navigationController presentMoviePlayerViewControllerAnimated:playerViewController];

我的url 不为零。

在 ios9 中 debug 时它可以工作,但在 releasexcode7 说时崩溃:

2015-10-15 14:53:04.808 ********[5110:1680634] NSScanner:无字符串 论点 2015-10-15 14:53:04.808 ********[5110:1680634] NSScanner: 零字符串参数 libc++abi.dylib: terminate_handler 意外 抛出异常

【问题讨论】:

    标签: ios objective-c ios9 mpmovieplayercontroller


    【解决方案1】:

    在 iOS9 中,不推荐使用 MPMoviePlayerController,您应该使用 AVPlayerController !

    【讨论】:

    • 是的,但由于某种原因我必须使用 MPMoviePlayerController。我们不能只为 iOS9
    • 你可以像 iOS9 然后 AVPlayerController else MPMoviePlayerController.
    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 2021-04-07
    • 2019-12-05
    • 1970-01-01
    • 2018-07-08
    • 2020-12-15
    • 2016-10-19
    • 1970-01-01
    相关资源
    最近更新 更多