Commit 1f13ad31 authored by Paul Yang's avatar Paul Yang Committed by Matt Caswell
Browse files

Add missing 'RETURN VALUES' sections in doc



All missing sections are added.

Reviewed-by: default avatarAndy Polyakov <appro@openssl.org>
Reviewed-by: default avatarMatt Caswell <matt@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/4976)
parent 82992a41
Loading
Loading
Loading
Loading
+21 −1
Original line number Diff line number Diff line
@@ -77,13 +77,33 @@ character in big endian format, UTF8String will be in UTF8 format.
Similar care should be take to ensure the data is in the correct format
when calling ASN1_STRING_set().

=head1 RETURN VALUES

ASN1_STRING_length() returns the length of the content of B<x>.

ASN1_STRING_get0_data() and ASN1_STRING_data() return an internal pointer to
the data of B<x>.

ASN1_STRING_dup() returns a valid B<ASN1_STRING> structure or B<NULL> if an
error occurred.

ASN1_STRING_cmp() returns an integer greater than, equal to, or less than 0,
according to whether B<a> is greater than, equal to, or less than B<b>.

ASN1_STRING_set() returns 1 on success or 0 on error.

ASN1_STRING_type() returns the type of B<x>.

ASN1_STRING_to_UTF8() returns the number of bytes in output string B<out> or a
negative value if an error occurred.

=head1 SEE ALSO

L<ERR_get_error(3)>

=head1 COPYRIGHT

Copyright 2002-2016 The OpenSSL Project Authors. All Rights Reserved.
Copyright 2002-2017 The OpenSSL Project Authors. All Rights Reserved.

Licensed under the OpenSSL license (the "License").  You may not use
this file except in compliance with the License.  You can obtain a copy
+9 −0
Original line number Diff line number Diff line
@@ -89,6 +89,15 @@ equivalent to:
 ASN1_STRFLGS_ESC_2253 | ASN1_STRFLGS_ESC_CTRL | ASN1_STRFLGS_ESC_MSB |
 ASN1_STRFLGS_UTF8_CONVERT | ASN1_STRFLGS_DUMP_UNKNOWN ASN1_STRFLGS_DUMP_DER

=head1 RETURN VALUES

ASN1_STRING_print_ex() and ASN1_STRING_print_ex_fp() return the number of
characters written or -1 if an error occurred.

ASN1_STRING_print() returns 1 on success or 0 on error.

ASN1_tag2str() returns a human-readable name of the specified ASN.1 B<tag>.

=head1 SEE ALSO

L<X509_NAME_print_ex(3)>,
+17 −1
Original line number Diff line number Diff line
@@ -271,6 +271,22 @@ a client and also echoes the request to standard output.
 BIO_flush(sbio);
 BIO_free_all(sbio);

=head1 RETURN VALUES

BIO_f_ssl() returns the SSL B<BIO_METHOD> structure.

BIO_set_ssl(), BIO_get_ssl(), BIO_set_ssl_mode(), BIO_set_ssl_renegotiate_bytes(),
BIO_set_ssl_renegotiate_timeout() and BIO_get_num_renegotiates() return 1 on
success or a value which is less than or equal to 0 if an error occurred.

BIO_new_ssl(), BIO_new_ssl_connect() and BIO_new_buffer_ssl_connect() return
a valid B<BIO> structure on success or B<NULL> if an error occurred.

BIO_ssl_copy_session_id() returns 1 on success or 0 on error.

BIO_do_handshake() returns 1 if the connection was established successfully.
A zero or negative value is returned if the connection could not be established.

=head1 HISTORY

In OpenSSL before 1.0.0 the BIO_pop() call was handled incorrectly,
@@ -282,7 +298,7 @@ be modified to handle this fix or they may free up an already freed BIO.

=head1 COPYRIGHT

Copyright 2000-2016 The OpenSSL Project Authors. All Rights Reserved.
Copyright 2000-2017 The OpenSSL Project Authors. All Rights Reserved.

Licensed under the OpenSSL license (the "License").  You may not use
this file except in compliance with the License.  You can obtain a copy
+8 −0
Original line number Diff line number Diff line
@@ -48,6 +48,14 @@ an offset into the opaque exdata part of the TYPE object.
TYPE_get_ex_data() is a function that calls CRYPTO_get_ex_data() with
an offset into the opaque exdata part of the TYPE object.

=head1 RETURN VALUES

TYPE_get_new_ex_index() returns a new index on success or -1 on error.

TYPE_set_ex_data() returns 1 on success or 0 on error.

TYPE_get_ex_data() returns the application data or NULL if an error occurred.

=head1 SEE ALSO

L<CRYPTO_get_ex_new_index(3)>.
+11 −0
Original line number Diff line number Diff line
@@ -133,6 +133,17 @@ the L<BIO_callback_ctrl(3)> page for more information. This function will be cal
in response to the application calling BIO_callback_ctrl(). The parameters for
the function have the same meaning as for BIO_callback_ctrl().

=head1 RETURN VALUES

BIO_get_new_index() returns the new BIO type value or -1 if an error occurred.

BIO_meth_new(int type, const char *name) returns a valid B<BIO_METHOD> or NULL
if an error occurred.

The B<BIO_meth_set> functions return 1 on success or 0 on error.

The B<BIO_meth_get> functions return the corresponding function pointers.

=head1 SEE ALSO

L<bio>, L<BIO_find_type>, L<BIO_ctrl>, L<BIO_read_ex>, L<BIO_new>
Loading