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

Unified Diff: net/der/input.cc

Issue 1125333005: RFC 2459 name comparison. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase Created 5 years, 4 months 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/der/input.cc
diff --git a/net/der/input.cc b/net/der/input.cc
index b5388a5f6999975dc89fb4119d5eefb666c53a41..0207cb8c6a142d99e14a24bfed4aa0cae9305681 100644
--- a/net/der/input.cc
+++ b/net/der/input.cc
@@ -23,6 +23,10 @@ bool Input::Equals(const Input& other) const {
return memcmp(data_, other.data_, len_) == 0;
}
+std::string Input::AsString() const {
+ return std::string(reinterpret_cast<const char*>(data_), len_);
+}
+
BitString::BitString(const Input& bytes, uint8_t unused_bits)
: bytes_(bytes), unused_bits_(unused_bits) {
DCHECK_LT(unused_bits, 8);

Powered by Google App Engine
This is Rietveld 408576698