diff --git a/server/abstractport.cpp b/server/abstractport.cpp
index d8bd247..05c66a7 100644
--- a/server/abstractport.cpp
+++ b/server/abstractport.cpp
@@ -17,8 +17,6 @@ You should have received a copy of the GNU General Public License
along with this program. If not, see
*/
-#define __STDC_FORMAT_MACROS
-
#include "abstractport.h"
#include "../common/abstractprotocol.h"
@@ -29,7 +27,6 @@ along with this program. If not, see
#include
#include
-#include
#include
#include
@@ -295,18 +292,18 @@ void AbstractPort::updatePacketListSequential()
n, x, y, burstSize);
qDebug("ibg = %g", ibg);
- qDebug("ibg1 = %" PRIu64, ibg1);
- qDebug("nb1 = %" PRIu64, nb1);
- qDebug("ibg2 = %" PRIu64, ibg2);
- qDebug("nb2 = %" PRIu64 "\n", nb2);
+ qDebug("ibg1 = %llu", ibg1);
+ qDebug("nb1 = %llu", nb1);
+ qDebug("ibg2 = %llu", ibg2);
+ qDebug("nb2 = %llu\n", nb2);
qDebug("ipg = %g", ipg);
- qDebug("ipg1 = %" PRIu64, ipg1);
- qDebug("npx1 = %" PRIu64, npx1);
- qDebug("npy1 = %" PRIu64, npy1);
- qDebug("ipg2 = %" PRIu64, ipg2);
- qDebug("npx2 = %" PRIu64, npx2);
- qDebug("npy2 = %" PRIu64 "\n", npy2);
+ qDebug("ipg1 = %llu", ipg1);
+ qDebug("npx1 = %llu", npx1);
+ qDebug("npy1 = %llu", npy1);
+ qDebug("ipg2 = %llu", ipg2);
+ qDebug("npx2 = %llu", npx2);
+ qDebug("npy2 = %llu\n", npy2);
if (n > 1)
loopNextPacketSet(x, n, 0, loopDelay);
@@ -478,16 +475,16 @@ void AbstractPort::updatePacketListInterleaved()
qDebug("numBursts = %g, numPackets = %g\n", numBursts, numPackets);
qDebug("ibg = %g", ibg);
- qDebug("ibg1 = %" PRIu64, _ibg1);
- qDebug("nb1 = %" PRIu64, _nb1);
- qDebug("ibg2 = %" PRIu64, _ibg2);
- qDebug("nb2 = %" PRIu64 "\n", _nb2);
+ qDebug("ibg1 = %llu", _ibg1);
+ qDebug("nb1 = %llu", _nb1);
+ qDebug("ibg2 = %llu", _ibg2);
+ qDebug("nb2 = %llu\n", _nb2);
qDebug("ipg = %g", ipg);
- qDebug("ipg1 = %" PRIu64, _ipg1);
- qDebug("np1 = %" PRIu64, _np1);
- qDebug("ipg2 = %" PRIu64, _ipg2);
- qDebug("np2 = %" PRIu64 "\n", _np2);
+ qDebug("ipg1 = %llu", _ipg1);
+ qDebug("np1 = %llu", _np1);
+ qDebug("ipg2 = %llu", _ipg2);
+ qDebug("np2 = %llu\n", _np2);
if (_ibg2 && (_ibg2 < minGap))
@@ -548,8 +545,8 @@ void AbstractPort::updatePacketListInterleaved()
numStreams++;
} // for i
- qDebug("minGap = %" PRIu64, minGap);
- qDebug("duration = %" PRIu64, duration);
+ qDebug("minGap = %llu", minGap);
+ qDebug("duration = %llu", duration);
uchar* buf;
int len;
@@ -584,7 +581,7 @@ void AbstractPort::updatePacketListInterleaved()
if (len <= 0)
continue;
- qDebug("q(%d) sec = %" PRIu64 " nsec = %" PRIu64, i, sec, nsec);
+ qDebug("q(%d) sec = %llu nsec = %llu", i, sec, nsec);
appendToPacketList(sec, nsec, buf, len);
lastPktTxSec = sec;
lastPktTxNsec = nsec;
@@ -624,7 +621,7 @@ void AbstractPort::updatePacketListInterleaved()
delayNsec += long(1e9);
delaySec--;
}
- qDebug("loop Delay = %" PRId64 "/%" PRId64, delaySec, delayNsec);
+ qDebug("loop Delay = %lld/%lld", delaySec, delayNsec);
setPacketListLoopMode(true, delaySec, delayNsec);
isSendQueueDirty_ = false;
}
diff --git a/server/devicemanager.cpp b/server/devicemanager.cpp
index 9631f24..a7b7b16 100644
--- a/server/devicemanager.cpp
+++ b/server/devicemanager.cpp
@@ -28,9 +28,6 @@ along with this program. If not, see
#include
-#define __STDC_FORMAT_MACROS
-#include
-
const quint64 kBcastMac = 0xffffffffffffULL;
inline UInt128 UINT128(OstEmul::Ip6Address x)
@@ -193,7 +190,7 @@ void DeviceManager::receivePacket(PacketBuffer *pktBuf)
offset += 4;
dstMac = (dstMac << 16) | qFromBigEndian(pktData + offset);
- qDebug("dstMac %012" PRIx64, dstMac);
+ qDebug("dstMac %012llx", dstMac);
// XXX: Treat multicast as bcast
if (isMacMcast(dstMac))
diff --git a/server/pcaptxthread.cpp b/server/pcaptxthread.cpp
index 8e18a58..1818a18 100644
--- a/server/pcaptxthread.cpp
+++ b/server/pcaptxthread.cpp
@@ -22,9 +22,6 @@ along with this program. If not, see
#include "statstuple.h"
#include "timestamp.h"
-#define __STDC_FORMAT_MACROS
-#include
-
PcapTxThread::PcapTxThread(const char *device)
{
char errbuf[PCAP_ERRBUF_SIZE] = "";
@@ -468,8 +465,8 @@ void PcapTxThread::updateStreamStats()
int d = pkts%packetListSize_;
qDebug("%s:", __FUNCTION__);
- qDebug("txPkts = %" PRIu64, pkts);
- qDebug("packetListSize_ = %" PRIu64, packetListSize_);
+ qDebug("txPkts = %llu", pkts);
+ qDebug("packetListSize_ = %llu", packetListSize_);
qDebug("c = %d, d = %d\n", c, d);
int i;