Skip to content

Commit

Permalink
segmentation fault with 'openssl s_client -prexit -keymatexport'
Browse files Browse the repository at this point in the history
Reviewed-by: Kurt Roeckx <[email protected]>
Reviewed-by: Rich Salz <[email protected]>
(Merged from openssl#1243)
  • Loading branch information
mmiyashita authored and Rich Salz committed Jun 21, 2016
1 parent 5388b8d commit 1d8b4eb
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion apps/s_client.c
Original file line number Diff line number Diff line change
Expand Up @@ -2633,7 +2633,8 @@ static void print_stuff(BIO *bio, SSL *s, int full)
#endif

SSL_SESSION_print(bio, SSL_get_session(s));
if (keymatexportlabel != NULL) {
if ((SSL_get_session(s) != NULL) &&
(keymatexportlabel != NULL)) {
BIO_printf(bio, "Keying material exporter:\n");
BIO_printf(bio, " Label: '%s'\n", keymatexportlabel);
BIO_printf(bio, " Length: %i bytes\n", keymatexportlen);
Expand Down

0 comments on commit 1d8b4eb

Please sign in to comment.