From 14a24fd14ff72ad618d647711875cefcedc3e8c9 Mon Sep 17 00:00:00 2001 From: Eugene Syromiatnikov Date: Thu, 31 Jul 2025 14:35:07 +0200 Subject: [PATCH] doc/man3/OPENSSL_malloc.pod: explicitly document freeptr value on failures MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Explicitly document that it is set to NULL, so can be passed to free() without additional checks. Signed-off-by: Eugene Syromiatnikov Reviewed-by: Saša Nedvědický Reviewed-by: Matt Caswell Reviewed-by: Paul Dale Reviewed-by: Neil Horman (Merged from https://github.com/openssl/openssl/pull/28059) --- doc/man3/OPENSSL_malloc.pod | 3 +++ 1 file changed, 3 insertions(+) diff --git a/doc/man3/OPENSSL_malloc.pod b/doc/man3/OPENSSL_malloc.pod index 9dd3bc1766..3cf2b77ccf 100644 --- a/doc/man3/OPENSSL_malloc.pod +++ b/doc/man3/OPENSSL_malloc.pod @@ -259,6 +259,9 @@ CRYPTO_clear_realloc(), CRYPTO_clear_realloc_array(), OPENSSL_strdup(), and OPENSSL_strndup() return a pointer to allocated memory or NULL on error. +OPENSSL_aligned_alloc() and OPENSSL_aligned_alloc_array() set B +to NULL on error. + CRYPTO_set_mem_functions() returns 1 on success or 0 on failure (almost always because allocations have already happened). -- 2.47.2