Don't call memcpy with NULL as source
authorKurt Roeckx <kurt@roeckx.be>
Thu, 15 Dec 2016 19:23:52 +0000 (20:23 +0100)
committerKurt Roeckx <kurt@roeckx.be>
Thu, 15 Dec 2016 20:47:21 +0000 (21:47 +0100)
commit3c55aec6e9f68ec45162e85434d2911fa67e8f15
treedb202b0df7af4d40b815e87af75df91d137a9003
parent0baae1c01f4975cc6b92b59e34d1a2a05ae48414
Don't call memcpy with NULL as source

Calling it with lenght 0 and NULL as source is undefined behaviour.

Reviewed-by: Rich Salz <rsalz@openssl.org>
GH: #2089
(cherry picked from commit eeab356c298248108b82157ef51172ba040646f7)
crypto/bn/bn_intern.c