X-Git-Url: https://git.openssl.org/?p=openssl.git;a=blobdiff_plain;f=doc%2Fcrypto%2FBN_CTX_new.pod;h=bbedbb17782cca05e60c14f3392e6cda78468262;hp=45c70fd4079e987a3d91815ecdbbeb88f088f975;hb=07e3b31fae98b985d3d2aad7066144b11833f688;hpb=e93f9a3284c799bb851afaeddd56ed502ba189b6 diff --git a/doc/crypto/BN_CTX_new.pod b/doc/crypto/BN_CTX_new.pod index 45c70fd407..bbedbb1778 100644 --- a/doc/crypto/BN_CTX_new.pod +++ b/doc/crypto/BN_CTX_new.pod @@ -10,23 +10,31 @@ BN_CTX_new, BN_CTX_init, BN_CTX_free - allocate and free BN_CTX structures BN_CTX *BN_CTX_new(void); + void BN_CTX_free(BN_CTX *c); + +Deprecated: + void BN_CTX_init(BN_CTX *c); - void BN_CTX_free(BN_CTX *c); =head1 DESCRIPTION -A B is a structure that holds temporary variables used by -library functions. Thus, it can be avoided to create and destroy -the temporary B objects whenever a library function is -called. +A B is a structure that holds B temporary variables used by +library functions. Since dynamic memory allocation to create Bs +is rather expensive when used in conjunction with repeated subroutine +calls, the B structure is used. -BN_CTX_new() allocated and initializes a B -structure. BN_CTX_init() initializes an existing uninitialized -B. +BN_CTX_new() allocates and initializes a B +structure. BN_CTX_free() frees the components of the B, and if it was created by BN_CTX_new(), also the structure itself. +If L has been used on the B, +L must be called before the B +may be freed by BN_CTX_free(). + +BN_CTX_init() (deprecated) initializes an existing uninitialized B. +This should not be used for new programs. Use BN_CTX_new() instead. =head1 RETURN VALUES @@ -38,7 +46,8 @@ BN_CTX_init() and BN_CTX_free() have no return values. =head1 SEE ALSO -L, L, L +L, L, L, +L =head1 HISTORY