From: Nick Mathewson Date: Wed, 16 May 2018 15:07:48 +0000 (-0400) Subject: Update documentation for PEM callback: error is now -1. X-Git-Tag: OpenSSL_1_1_1-pre7~10 X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=bbbf752a3c8b5a966bcb48fc71a3dc03832e7b27;p=oweals%2Fopenssl.git Update documentation for PEM callback: error is now -1. In previous versions of OpenSSL, the documentation for PEM_read_* said: The callback B return the number of characters in the passphrase or 0 if an error occurred. But since c82c3462267afdbbaa5, 0 is now treated as a non-error return value. Applications that want to indicate an error need to return -1 instead. Reviewed-by: Rich Salz Reviewed-by: Richard Levitte (Merged from https://github.com/openssl/openssl/pull/6271) --- diff --git a/doc/man3/PEM_read_bio_PrivateKey.pod b/doc/man3/PEM_read_bio_PrivateKey.pod index 9f62140ce6..4fb4d1159a 100644 --- a/doc/man3/PEM_read_bio_PrivateKey.pod +++ b/doc/man3/PEM_read_bio_PrivateKey.pod @@ -295,7 +295,7 @@ for it twice) if B is 1. The B parameter has the same value as the B parameter passed to the PEM routine. It allows arbitrary data to be passed to the callback by the application (for example a window handle in a GUI application). The callback -B return the number of characters in the passphrase or 0 if +B return the number of characters in the passphrase or -1 if an error occurred. =head1 EXAMPLES