summaryrefslogtreecommitdiffstats
path: root/src/crypto/ec/ec_test.cc
diff options
context:
space:
mode:
Diffstat (limited to 'src/crypto/ec/ec_test.cc')
-rw-r--r--src/crypto/ec/ec_test.cc3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/crypto/ec/ec_test.cc b/src/crypto/ec/ec_test.cc
index 74685eb..5af42d5 100644
--- a/src/crypto/ec/ec_test.cc
+++ b/src/crypto/ec/ec_test.cc
@@ -125,6 +125,9 @@ bool Testd2i_ECPrivateKey() {
}
ScopedOpenSSLString x_hex(BN_bn2hex(x.get()));
ScopedOpenSSLString y_hex(BN_bn2hex(y.get()));
+ if (!x_hex || !y_hex) {
+ return false;
+ }
if (0 != strcmp(
x_hex.get(),
"c81561ecf2e54edefe6617db1c7a34a70744ddb261f269b83dacfcd2ade5a681") ||