diff --git a/plugins/samplesource/filesource/filesourcegui.cpp b/plugins/samplesource/filesource/filesourcegui.cpp index 688856ae5..c8e07638f 100644 --- a/plugins/samplesource/filesource/filesourcegui.cpp +++ b/plugins/samplesource/filesource/filesourcegui.cpp @@ -257,10 +257,10 @@ void FileSourceGui::updateWithStreamTime() QString s_time = t.toString("hh:mm:ss"); ui->relTimeText->setText(s_timems); - quint64 startingTimeStampMsec = m_startingTimeStamp * 1000; + quint64 startingTimeStampMsec = (quint64) m_startingTimeStamp * 1000LL; QDateTime dt = QDateTime::fromMSecsSinceEpoch(startingTimeStampMsec); - dt = dt.addSecs(t_sec); - dt = dt.addMSecs(t_msec); + dt = dt.addSecs((quint64) t_sec); + dt = dt.addMSecs((quint64) t_msec); QString s_date = dt.toString("yyyy-MM-dd hh:mm:ss.zzz"); ui->absTimeText->setText(s_date); diff --git a/plugins/samplesource/sdrdaemon/sdrdaemongui.cpp b/plugins/samplesource/sdrdaemon/sdrdaemongui.cpp index 4eb963699..bae5edb37 100644 --- a/plugins/samplesource/sdrdaemon/sdrdaemongui.cpp +++ b/plugins/samplesource/sdrdaemon/sdrdaemongui.cpp @@ -331,9 +331,9 @@ void SDRdaemonGui::updateWithStreamData() void SDRdaemonGui::updateWithStreamTime() { - quint64 startingTimeStampMsec = (m_startingTimeStamp.tv_sec * 1000) + (m_startingTimeStamp.tv_usec / 1000); - QDateTime dt = QDateTime::fromMSecsSinceEpoch(startingTimeStampMsec); - QString s_date = dt.toString("yyyy-MM-dd hh:mm:ss.zzz"); + quint64 startingTimeStampMsec = ((quint64) m_startingTimeStamp.tv_sec * 1000LL) + ((quint64) m_startingTimeStamp.tv_usec / 1000LL); + QDateTime dt = QDateTime::fromMSecsSinceEpoch(startingTimeStampMsec); + QString s_date = dt.toString("yyyy-MM-dd hh:mm:ss.zzz"); ui->absTimeText->setText(s_date); if (m_syncLocked) {