diff --git a/common/pcapfileformat.cpp b/common/pcapfileformat.cpp index 9a0a03f..95991fa 100644 --- a/common/pcapfileformat.cpp +++ b/common/pcapfileformat.cpp @@ -480,7 +480,7 @@ _non_pdml: stream->mutable_control()->set_num_packets(1); // setup packet rate to the timing in pcap (as close as possible) - const uint kUsecsInSec = uint(1e6); + const double kUsecsInSec = 1e6; uint usec = (pktHdr.tsSec*kUsecsInSec + pktHdr.tsUsec); uint delta = usec - lastUsec; diff --git a/common/pdmlprotocols.cpp b/common/pdmlprotocols.cpp index ec1f99d..200cafd 100644 --- a/common/pdmlprotocols.cpp +++ b/common/pdmlprotocols.cpp @@ -177,7 +177,7 @@ void PdmlFrameProtocol::unknownFieldHandler(QString name, int /*pos*/, if (decimal >= 0) { - const uint kNsecsInSec = 1000000000; + const double kNsecsInSec = 1e9; uint sec = delta.left(decimal).toUInt(); uint nsec = delta.mid(decimal+1).toUInt(); uint ipg = sec*kNsecsInSec + nsec;