Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-41136

Compiling on OSX Yosemite fails due to missing explicit cast

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: P1: Critical
    • Resolution: Done
    • Affects Version/s: 5.3.1
    • Fix Version/s: 5.4.0
    • Component/s: Multimedia
    • Labels:
      None
    • Platform/s:
      macOS
    • Commits:
      8d5114a63051128992291356440ecff9ab2ef6b6

      Description

      Building QT 5.3.1 on OSX 10.10 Yosemite Beta 2 fails, since the enum AVPlayerStatus is not accepting rvalue NSInteger.

      Explicitly casting the integer value to AVPlayerStatus fixes the problem.

      --- a/qtmultimedia/src/plugins/avfoundation/mediaplayer/avfmediaplayersession.mm
      +++ b/qtmultimedia/src/plugins/avfoundation/mediaplayer/avfmediaplayersession.mm
      @@ -322,7 +322,7 @@ static void *AVFMediaPlayerSessionObserverCurrentItemObservationContext = &AVFMe
           //AVPlayerItem "status" property value observer.
           if (context == AVFMediaPlayerSessionObserverStatusObservationContext)
           {
      -        AVPlayerStatus status = [[change objectForKey:NSKeyValueChangeNewKey] integerValue];
      +        AVPlayerStatus status = (AVPlayerStatus)[[change objectForKey:NSKeyValueChangeNewKey] integerValue];
               switch (status)
               {
                   //Indicates that the status of the player is not yet known because
      

        Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

          Activity

            People

            Assignee:
            ylopes Yoann Lopes
            Reporter:
            kelloggsfrost Jens Cornelis
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved:

                Gerrit Reviews

                There are no open Gerrit changes