summaryrefslogtreecommitdiff
path: root/include/openssl/buffer.h
diff options
context:
space:
mode:
authorRich Salz <rsalz@akamai.com>2019-10-17 15:45:34 -0400
committerRichard Levitte <levitte@openssl.org>2019-10-17 23:19:59 +0200
commit3d48457478bd61030c370e4090c1462fc4453d81 (patch)
treecf36ad0667881411cb5b02f44411c03e510e12f2 /include/openssl/buffer.h
parent8c77d45adab101f10b323de3d59fb47b8f8d3a93 (diff)
downloadopenssl-new-3d48457478bd61030c370e4090c1462fc4453d81.tar.gz
Replace BUF_ string function calls with OPENSSL_ ones
Deprecate the BUF_ string macros Reviewed-by: Dmitry Belyavskiy <beldmit@gmail.com> Reviewed-by: Richard Levitte <levitte@openssl.org> (Merged from https://github.com/openssl/openssl/pull/10207)
Diffstat (limited to 'include/openssl/buffer.h')
-rw-r--r--include/openssl/buffer.h18
1 files changed, 8 insertions, 10 deletions
diff --git a/include/openssl/buffer.h b/include/openssl/buffer.h
index c3cf216147..49581b826a 100644
--- a/include/openssl/buffer.h
+++ b/include/openssl/buffer.h
@@ -30,16 +30,14 @@ extern "C" {
# include <stddef.h>
# include <sys/types.h>
-/*
- * These names are outdated as of OpenSSL 1.1; a future release
- * will move them to be deprecated.
- */
-# define BUF_strdup(s) OPENSSL_strdup(s)
-# define BUF_strndup(s, size) OPENSSL_strndup(s, size)
-# define BUF_memdup(data, size) OPENSSL_memdup(data, size)
-# define BUF_strlcpy(dst, src, size) OPENSSL_strlcpy(dst, src, size)
-# define BUF_strlcat(dst, src, size) OPENSSL_strlcat(dst, src, size)
-# define BUF_strnlen(str, maxlen) OPENSSL_strnlen(str, maxlen)
+# if !OPENSSL_API_3
+# define BUF_strdup(s) OPENSSL_strdup(s)
+# define BUF_strndup(s, size) OPENSSL_strndup(s, size)
+# define BUF_memdup(data, size) OPENSSL_memdup(data, size)
+# define BUF_strlcpy(dst, src, size) OPENSSL_strlcpy(dst, src, size)
+# define BUF_strlcat(dst, src, size) OPENSSL_strlcat(dst, src, size)
+# define BUF_strnlen(str, maxlen) OPENSSL_strnlen(str, maxlen)
+# endif
struct buf_mem_st {
size_t length; /* current number of bytes */