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

Unified Diff: net/tools/quic/quic_packet_printer_bin.cc

Issue 2603723002: Add a new QUIC platform API for text utilities. (Closed)
Patch Set: net/tools/quic/quic_packet_printer_bin.cc 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
« no previous file with comments | « net/tools/quic/quic_http_response_cache_test.cc ('k') | net/tools/quic/quic_simple_client_bin.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/tools/quic/quic_packet_printer_bin.cc
diff --git a/net/tools/quic/quic_packet_printer_bin.cc b/net/tools/quic/quic_packet_printer_bin.cc
index 1ce089b764f6bc0f4befe9128bb974027cf2ac79..2ba19b93a04f893531d193b825eb54d5d5ceb455 100644
--- a/net/tools/quic/quic_packet_printer_bin.cc
+++ b/net/tools/quic/quic_packet_printer_bin.cc
@@ -36,10 +36,10 @@
#include <string>
#include "base/command_line.h"
-#include "base/strings/string_number_conversions.h"
#include "base/strings/utf_string_conversions.h"
#include "net/quic/core/quic_framer.h"
#include "net/quic/core/quic_utils.h"
+#include "net/quic/platform/api/quic_text_utils.h"
using std::cerr;
using std::string;
@@ -103,7 +103,7 @@ class QuicPacketPrinter : public QuicFramerVisitorInterface {
bool OnStreamFrame(const QuicStreamFrame& frame) override {
cerr << "OnStreamFrame: " << frame;
cerr << " data: { "
- << QuicUtils::HexEncode(frame.data_buffer, frame.data_length)
+ << QuicTextUtils::HexEncode(frame.data_buffer, frame.data_length)
<< " }\n";
return true;
}
@@ -181,7 +181,7 @@ int main(int argc, char* argv[]) {
<< " Usage: " << args[0] << " client|server <hex>\n";
return 1;
}
- string hex = net::QuicUtils::HexDecode(ArgToString(args[1]));
+ string hex = net::QuicTextUtils::HexDecode(argv[2]);
net::QuicVersionVector versions = net::AllSupportedVersions();
// Fake a time since we're not actually generating acks.
net::QuicTime start(net::QuicTime::Zero());
« no previous file with comments | « net/tools/quic/quic_http_response_cache_test.cc ('k') | net/tools/quic/quic_simple_client_bin.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698