From 05a9dd57434376d61637c30975d906b0d9a5d25d Mon Sep 17 00:00:00 2001 From: Srivats P Date: Fri, 31 Mar 2023 16:58:52 +0530 Subject: [PATCH] Rename PcapRxStats::id_ as PcapRxStats::portId_ Better code clarity --- server/pcaprxstats.cpp | 6 +++--- server/pcaprxstats.h | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/server/pcaprxstats.cpp b/server/pcaprxstats.cpp index 1f424a1..ef59459 100644 --- a/server/pcaprxstats.cpp +++ b/server/pcaprxstats.cpp @@ -35,7 +35,7 @@ PcapRxStats::PcapRxStats(const char *device, StreamStats &portStreamStats, int i handle_ = NULL; - id_ = id; + portId_ = id; timing_ = StreamTiming::instance(); } @@ -122,8 +122,8 @@ _skip_filter: case 1: { uint ttagId, guid; if (SignProtocol::packetTtagId(data, hdr->caplen, &ttagId, &guid)) { - timing_->recordRxTime(id_, guid, ttagId, hdr->ts); - qDebug("XXXXX [%d RX] %ld:%ld ttag %u guid %u", id_, + timing_->recordRxTime(portId_, guid, ttagId, hdr->ts); + qDebug("XXXXX [%d RX] %ld:%ld ttag %u guid %u", portId_, hdr->ts.tv_sec, long(hdr->ts.tv_usec), ttagId, guid); } if (guid != SignProtocol::kInvalidGuid) { diff --git a/server/pcaprxstats.h b/server/pcaprxstats.h index 6126e65..5f97ca3 100644 --- a/server/pcaprxstats.h +++ b/server/pcaprxstats.h @@ -50,7 +50,7 @@ private: volatile State state_; bool isDirectional_; - int id_; // FIXME: rename to portId_ + int portId_; StreamTiming *timing_{nullptr}; };