From 6855e9cf2656afba9e6dfd96c9c52f76e635e5bd Mon Sep 17 00:00:00 2001 From: Et7f3 Date: Sat, 6 Apr 2024 21:09:30 +0200 Subject: [PATCH] ossl_store.pod: Correct the example of OSSL_STORE API usage Reviewed-by: Matt Caswell Reviewed-by: Tomas Mraz (Merged from https://github.com/openssl/openssl/pull/24056) (cherry picked from commit d5412c94a399d3923b2dec2431ead60288d857c8) --- doc/man7/ossl_store.pod | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/doc/man7/ossl_store.pod b/doc/man7/ossl_store.pod index 3152cff1042..81908def36a 100644 --- a/doc/man7/ossl_store.pod +++ b/doc/man7/ossl_store.pod @@ -44,7 +44,11 @@ other encoding is undefined. =head2 A generic call - OSSL_STORE_CTX *ctx = OSSL_STORE_open("file:/foo/bar/data.pem"); + #include /* for UI_get_default_method */ + #include + + OSSL_STORE_CTX *ctx = OSSL_STORE_open("file:/foo/bar/data.pem", + UI_get_default_method(), NULL, NULL, NULL); /* * OSSL_STORE_eof() simulates file semantics for any repository to signal @@ -65,6 +69,7 @@ other encoding is undefined. PEM_write_X509(stdout, OSSL_STORE_INFO_get0_CERT(info)); break; } + OSSL_STORE_INFO_free(info); } OSSL_STORE_close(ctx); -- 2.47.2