diff options
Diffstat (limited to 'lib/edi/PFT.cpp')
-rw-r--r-- | lib/edi/PFT.cpp | 20 |
1 files changed, 13 insertions, 7 deletions
diff --git a/lib/edi/PFT.cpp b/lib/edi/PFT.cpp index 4348f14..aff7929 100644 --- a/lib/edi/PFT.cpp +++ b/lib/edi/PFT.cpp @@ -488,14 +488,15 @@ void PFT::pushPFTFrag(const Fragment &fragment) auto& p = m_afbuilders.at(fragment.Pseq()); p.pushPFTFrag(fragment); -#if 0 - etiLog.log(debug, "Got frag %u:%u, afbuilders: ", - fragment.Pseq(), fragment.Findex()); - for (const auto &k : m_afbuilders) { - const bool isNextPseq = (m_next_pseq == k.first); - etiLog.level(debug) << (isNextPseq ? "->" : " ") << k.first << " " << k.second.visualise(); + if (m_verbose) { + etiLog.log(debug, "Got frag %u:%u, afbuilders: ", + fragment.Pseq(), fragment.Findex()); + for (const auto &k : m_afbuilders) { + const bool isNextPseq = (m_next_pseq == k.first); + etiLog.level(debug) << (isNextPseq ? "->" : " ") << + k.first << " " << k.second.visualise(); + } } -#endif } @@ -555,6 +556,11 @@ void PFT::setMaxDelay(size_t num_af_packets) m_max_delay = num_af_packets; } +void PFT::setVerbose(bool enable) +{ + m_verbose = enable; +} + void PFT::incrementNextPseq() { if (m_afbuilders.count(m_next_pseq - NUM_AFBUILDERS_TO_KEEP) > 0) { |