assert non-NULL ptrs before calling mem funcs
commit190263bb7a56fc775b50a6cd0dc91820d2b2e5eb
authorJeffrey Altman <jaltman@secure-endpoints.com>
Thu, 20 Jan 2022 03:55:33 +0000 (19 22:55 -0500)
committerJeffrey Altman <jaltman@auristor.com>
Mon, 24 Jan 2022 05:07:51 +0000 (24 00:07 -0500)
tree51e4915fe226192ba0a0426148aaffa6f3885f01
parentd35c9b2d67188f9c6973d9ad580a42814e046e7b
assert non-NULL ptrs before calling mem funcs

The definitions of memcpy(), memmove(), and memset() state that
the behaviour is undefined if any of the pointer arguments are
NULL, and some compilers are known to make use of this to
optimise away existing NULL checks in the source.

Change-Id: I489bc256e3eac7ff41d91becb0b43aba73dbb3f9
Link: https://www.imperialviolet.org/2016/06/26/nonnull.html
lib/asn1/der_copy.c
lib/asn1/der_get.c
lib/asn1/der_put.c
lib/gssapi/krb5/arcfour.c
lib/krb5/pac.c
lib/krb5/store_emem.c