You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@trafficserver.apache.org by ma...@apache.org on 2018/06/06 06:15:55 UTC
[trafficserver] branch quic-latest updated: Check debug tag before
print debug msg of frame
This is an automated email from the ASF dual-hosted git repository.
masaori pushed a commit to branch quic-latest
in repository https://gitbox.apache.org/repos/asf/trafficserver.git
The following commit(s) were added to refs/heads/quic-latest by this push:
new cd04170 Check debug tag before print debug msg of frame
cd04170 is described below
commit cd041706743783a52144e0bc367e1b75680301aa
Author: Masaori Koshiba <ma...@apache.org>
AuthorDate: Wed Jun 6 15:15:30 2018 +0900
Check debug tag before print debug msg of frame
---
iocore/net/QUICNetVConnection.cc | 17 ++++++++++-------
1 file changed, 10 insertions(+), 7 deletions(-)
diff --git a/iocore/net/QUICNetVConnection.cc b/iocore/net/QUICNetVConnection.cc
index fba95e6..3bf73aa 100644
--- a/iocore/net/QUICNetVConnection.cc
+++ b/iocore/net/QUICNetVConnection.cc
@@ -1169,13 +1169,14 @@ QUICNetVConnection::_store_frame(ats_unique_buf &buf, size_t &len, bool &retrans
ink_assert(max_size > len);
- char msg[1024];
size_t l = 0;
size_t n = frame->store(buf.get() + len, &l, max_size - len);
if (n > 0) {
- // TODO: check debug build
- frame->debug_msg(msg, sizeof(msg));
- QUICConDebug("[TX] %s", msg);
+ if (is_debug_tag_set(QUIC_DEBUG_TAG.data())) {
+ char msg[1024];
+ frame->debug_msg(msg, sizeof(msg));
+ QUICConDebug("[TX] %s", msg);
+ }
len += l;
return;
@@ -1184,9 +1185,11 @@ QUICNetVConnection::_store_frame(ats_unique_buf &buf, size_t &len, bool &retrans
// split frame
auto new_frame = QUICFrameFactory::split_frame(frame.get(), max_size - len);
- // TODO: check debug build
- frame->debug_msg(msg, sizeof(msg));
- QUICConDebug("[TX] %s", msg);
+ if (is_debug_tag_set(QUIC_DEBUG_TAG.data())) {
+ char msg[1024];
+ frame->debug_msg(msg, sizeof(msg));
+ QUICConDebug("[TX] %s", msg);
+ }
ink_assert(frame->store(buf.get() + len, &l, max_size - len) > 0);
ink_assert(new_frame != nullptr);
--
To stop receiving notification emails like this one, please contact
masaori@apache.org.