Don't call memcmp with a NULL pointer
authorMatt Caswell <matt@openssl.org>
Sat, 4 Mar 2017 23:58:03 +0000 (23:58 +0000)
committerMatt Caswell <matt@openssl.org>
Sat, 4 Mar 2017 23:58:03 +0000 (23:58 +0000)
commite6941c7814bb25729d65e1f8e87d1c110a0cbe7e
tree2a1b30107ce599aa7132b5ea4cc405f5f38c4c6a
parentee7002266cbdcfcfe002c94396795c9fb3d5a337
Don't call memcmp with a NULL pointer

If early data is sent to a server, but ALPN is not used then memcmp is
called with a NULL pointer which is undefined behaviour.

Fixes #2841

Reviewed-by: Kurt Roeckx <kurt@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/2845)
ssl/statem/extensions.c