Ticket #10524: c++standard_2.patch

File c++standard_2.patch, 1.1 KB (added by Gary Buhrmaster <gary.buhrmaster@…>, 8 years ago)
  • mythtv/libs/libmythtv/mythplayer.cpp

    diff --git a/mythtv/libs/libmythtv/mythplayer.cpp b/mythtv/libs/libmythtv/mythplayer.cpp
    index 1261340..da15c51 100644
    a b  
    88#include <cstdlib>
    99#include <cerrno>
    1010#include <ctime>
    11 #include <cmath>
    1211
    1312// POSIX headers
    1413#include <unistd.h>
    using namespace std; 
    2524#include <QCoreApplication>
    2625#include <QKeyEvent>
    2726#include <QDir>
     27#include <QtCore/qnumeric.h>
    2828
    2929// MythTV headers
    3030#include "mthread.h"
    extern "C" { 
    7474#define round(x) ((int) ((x) + 0.5))
    7575#endif
    7676
    77 #if CONFIG_DARWIN
    78 extern "C" {
    79 int isnan(double);
    80 }
    81 #endif
    82 
    8377static unsigned dbg_ident(const MythPlayer*);
    8478
    8579#define LOC      QString("Player(%1): ").arg(dbg_ident(this),0,36)
    void MythPlayer::SetScanType(FrameScanType scan) 
    795789void MythPlayer::SetVideoParams(int width, int height, double fps,
    796790                                FrameScanType scan)
    797791{
    798     if (width < 1 || height < 1 || isnan(fps))
     792    if (width < 1 || height < 1 || qIsNaN(fps))
    799793        return;
    800794
    801795    video_dim      = QSize((width + 15) & ~0xf, (height + 15) & ~0xf);