Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(242)

Unified Diff: net/quic/core/quic_flow_controller.cc

Issue 2591143003: Add QuicStrCat. (Closed)
Patch Set: fix include Created 4 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: net/quic/core/quic_flow_controller.cc
diff --git a/net/quic/core/quic_flow_controller.cc b/net/quic/core/quic_flow_controller.cc
index 12c0368d4c172c63b8d5107e9a75157dac0a2634..19591a0c32d24f7acdde7c226f2ecc3b0403a7f0 100644
--- a/net/quic/core/quic_flow_controller.cc
+++ b/net/quic/core/quic_flow_controller.cc
@@ -9,6 +9,7 @@
#include "net/quic/core/quic_connection.h"
#include "net/quic/core/quic_flags.h"
#include "net/quic/core/quic_packets.h"
+#include "net/quic/platform/api/quic_str_cat.h"
namespace net {
@@ -77,11 +78,8 @@ void QuicFlowController::AddBytesSent(QuicByteCount bytes_sent) {
// This is an error on our side, close the connection as soon as possible.
connection_->CloseConnection(
QUIC_FLOW_CONTROL_SENT_TOO_MUCH_DATA,
- base::StringPrintf(
- "%llu bytes over send window offset",
- static_cast<unsigned long long>(send_window_offset_ -
- (bytes_sent_ + bytes_sent)))
- .c_str(),
+ QuicStrCat(send_window_offset_ - (bytes_sent_ + bytes_sent),
+ "bytes over send window offset"),
ConnectionCloseBehavior::SEND_CONNECTION_CLOSE_PACKET);
return;
}

Powered by Google App Engine
This is Rietveld 408576698