summaryrefslogtreecommitdiff
path: root/src/lib
diff options
context:
space:
mode:
authormiod <>2014-07-13 15:41:33 +0000
committermiod <>2014-07-13 15:41:33 +0000
commitcba45fbd725357be36de539c7ac2dc1c2e67ab27 (patch)
treea5939693d4fe30dd4bc44acb695b877873d79ac8 /src/lib
parentb3fa9f2845f7039838068e77b5d6863c05d3c3da (diff)
downloadopenbsd-cba45fbd725357be36de539c7ac2dc1c2e67ab27.tar.gz
openbsd-cba45fbd725357be36de539c7ac2dc1c2e67ab27.tar.bz2
openbsd-cba45fbd725357be36de539c7ac2dc1c2e67ab27.zip
Warn about the use of BUF_strdup.
Diffstat (limited to 'src/lib')
-rw-r--r--src/lib/libssl/src/doc/crypto/BUF_MEM_new.pod6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/lib/libssl/src/doc/crypto/BUF_MEM_new.pod b/src/lib/libssl/src/doc/crypto/BUF_MEM_new.pod
index a83f46f896..2805755869 100644
--- a/src/lib/libssl/src/doc/crypto/BUF_MEM_new.pod
+++ b/src/lib/libssl/src/doc/crypto/BUF_MEM_new.pod
@@ -45,10 +45,12 @@ B<len>. Any data already in the buffer is preserved if it increases in
45size. 45size.
46 46
47BUF_strdup() copies a null terminated string into a block of allocated memory 47BUF_strdup() copies a null terminated string into a block of allocated memory
48and returns a pointer to the allocated block. 48and returns a pointer to the allocated block. Unlike the system strdup()
49function, BUF_strdup() will accept a NULL argument and will return NULL in
50that case. Its use in new programes is discouraged.
49 51
50The memory allocated from BUF_strdup() should be freed up using the 52The memory allocated from BUF_strdup() should be freed up using the
51OPENSSL_free() function. 53free() function.
52 54
53=head1 RETURN VALUES 55=head1 RETURN VALUES
54 56