aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/common/tortls.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/common/tortls.c b/src/common/tortls.c
index 4cfe94e182..98840c15cf 100644
--- a/src/common/tortls.c
+++ b/src/common/tortls.c
@@ -2631,10 +2631,11 @@ SSL_get_server_random(SSL *s, uint8_t *out, size_t len)
static size_t
SSL_SESSION_get_master_key(SSL_SESSION *s, uint8_t *out, size_t len)
{
+ tor_assert(s);
if (len == 0)
return s->master_key_length;
tor_assert(len == (size_t)s->master_key_length);
- tor_assert(s->master_key);
+ tor_assert(out);
memcpy(out, s->master_key, len);
return len;
}