commit | 0d264bf088960285bc9f4e31250a9a3bfe8e03bf | [log] [tgz] |
---|---|---|
author | Tao Bao <tbao@google.com> | Thu Mar 23 19:55:35 2017 +0000 |
committer | Gerrit Code Review <noreply-gerritcodereview@google.com> | Thu Mar 23 19:55:35 2017 +0000 |
tree | a897e3d5c891182867dd5206a5591079b2924db4 | |
parent | 577c6688610ef0f9e3aefe9326e5ee4886c79a36 [diff] | |
parent | 8524faddd3ab954893312c249c277981e6c26d75 [diff] |
Merge "Checking unsigned variable less than zero"
diff --git a/asn1_decoder.cpp b/asn1_decoder.cpp index a9dfccc..285214f 100644 --- a/asn1_decoder.cpp +++ b/asn1_decoder.cpp
@@ -19,14 +19,14 @@ #include <stdint.h> int asn1_context::peek_byte() const { - if (length_ <= 0) { + if (length_ == 0) { return -1; } return *p_; } int asn1_context::get_byte() { - if (length_ <= 0) { + if (length_ == 0) { return -1; }