Ticket #3392: mythtv-remoteutil-local_pathname-recording_not_available.patch

File mythtv-remoteutil-local_pathname-recording_not_available.patch, 662 bytes (added by sphery <mtdean@…>, 13 years ago)
  • libs/libmythtv/remoteutil.cpp

     
     1#include <qfile.h>
    12#include <qstringlist.h>
    23
    34#include "util.h"
     
    117118        (!strlist[0].toInt()))
    118119        return false;
    119120
    120     pginfo->pathname = strlist[1];
     121    // Only modify the pathname if the recording file is available locally on
     122    // this host
     123    QString localpath = strlist[1];
     124    QFile checkFile(localpath);
     125    if (checkFile.exists())
     126        pginfo->pathname = localpath;
     127
    121128    return true;
    122129}
    123130