Ticket #5526: qtimefromstring.patch

File qtimefromstring.patch, 1.4 KB (added by Ben Dailey <benddailey@…>, 12 years ago)

Fix for QTime::fromString problem

  • libs/libmythtv/jobqueue.cpp

     
    11231123            QString("Currently set to run new jobs from %1 to %2")
    11241124                    .arg(queueStartTimeStr).arg(queueEndTimeStr));
    11251125
    1126     queueStartTime = QTime::fromString(queueStartTimeStr);
     1126    queueStartTime = QTime::fromString(queueStartTimeStr, "hh:mm");
    11271127    if (!queueStartTime.isValid())
    11281128    {
    11291129        VERBOSE(VB_IMPORTANT, "Invalid JobQueueWindowStart time, using 00:00");
    11301130        queueStartTime = QTime(0, 0);
    11311131    }
    11321132
    1133     queueEndTime = QTime::fromString(queueEndTimeStr);
     1133    queueEndTime = QTime::fromString(queueEndTimeStr, "hh:mm");
    11341134    if (!queueEndTime.isValid())
    11351135    {
    11361136        VERBOSE(VB_IMPORTANT, "Invalid JobQueueWindowEnd time, using 23:59");
  • programs/mythshutdown/main.cpp

     
    174174QDateTime getDailyWakeupTime(QString sPeriod)
    175175{
    176176    QString sTime = getGlobalSetting(sPeriod, "00:00");
    177     QTime tTime = QTime::fromString(sTime);
     177    QTime tTime = QTime::fromString(sTime, "hh:mm");
    178178    QDateTime dtDateTime = QDateTime(QDate::currentDate(), tTime);
    179179
    180180    return dtDateTime;