Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mono/boringssl.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBrian Smith <brian@briansmith.org>2015-08-06 17:42:49 +0300
committerAdam Langley <agl@google.com>2015-08-07 03:48:03 +0300
commit7b5f08edb81accd896eb93359d6c61c1a7a1f791 (patch)
treee8f22d3c128060665dcaabeffbc7405b8795afcd /crypto/test
parent07bf9f69ba54294113bac938934180fb42ed3c4e (diff)
Fix null pointer dereference in file_test.cc.
The error condition was checked for, but the return statement was missing. Change-Id: I92f89809a7a112fdece49a2a8a8628ff2da8e0da Reviewed-on: https://boringssl-review.googlesource.com/5610 Reviewed-by: David Benjamin <davidben@chromium.org> Reviewed-by: Adam Langley <agl@google.com>
Diffstat (limited to 'crypto/test')
-rw-r--r--crypto/test/file_test.cc1
1 files changed, 1 insertions, 0 deletions
diff --git a/crypto/test/file_test.cc b/crypto/test/file_test.cc
index 8df6f9ae..6723350a 100644
--- a/crypto/test/file_test.cc
+++ b/crypto/test/file_test.cc
@@ -128,6 +128,7 @@ FileTest::ReadResult FileTest::ReadNext() {
const char *delimiter = FindDelimiter(buf);
if (delimiter == nullptr) {
fprintf(stderr, "Line %u: Could not parse attribute.\n", line_);
+ return kReadError;
}
std::string key = StripSpace(buf, delimiter - buf);
std::string value = StripSpace(delimiter + 1,