]> git.ipfire.org Git - thirdparty/openssl.git/commitdiff
Rename DECLARE*STACK_OF to DEFINE*STACK_OF
authorDr. Stephen Henson <steve@openssl.org>
Mon, 28 Dec 2015 00:04:33 +0000 (00:04 +0000)
committerDr. Stephen Henson <steve@openssl.org>
Thu, 7 Jan 2016 18:00:51 +0000 (18:00 +0000)
Applications wishing to include their own stacks now just need to include

DEFINE_STACK_OF(foo)

in a header file.

Reviewed-by: Richard Levitte <levitte@openssl.org>
38 files changed:
crypto/asn1/ameth_lib.c
crypto/asn1/asn_mime.c
crypto/async/async_locl.h
crypto/cms/cms_lcl.h
crypto/engine/eng_int.h
crypto/evp/evp_pbe.c
crypto/evp/pmeth_lib.c
crypto/ex_data.c
crypto/include/internal/ct_int.h
crypto/lock.c
crypto/objects/o_names.c
crypto/objects/obj_xref.c
crypto/store/str_mem.c
crypto/ts/ts_lcl.h
crypto/x509/by_dir.c
crypto/x509/x_name.c
crypto/x509v3/pcy_int.h
include/openssl/asn1.h
include/openssl/asn1t.h
include/openssl/bio.h
include/openssl/cms.h
include/openssl/conf.h
include/openssl/crypto.h
include/openssl/ocsp.h
include/openssl/pkcs12.h
include/openssl/pkcs7.h
include/openssl/safestack.h
include/openssl/srp.h
include/openssl/ssl.h
include/openssl/store.h
include/openssl/ts.h
include/openssl/txt_db.h
include/openssl/ui.h
include/openssl/x509.h
include/openssl/x509_vfy.h
include/openssl/x509v3.h
ssl/ssl_locl.h
util/mkstack.pl

index cca4a791411a71ef858561103322ba0577e4300b..1febfe91ba7b093d46c6d7c8705962046bd2ffab 100644 (file)
@@ -92,7 +92,7 @@ static const EVP_PKEY_ASN1_METHOD *standard_methods[] = {
 };
 
 typedef int sk_cmp_fn_type(const char *const *a, const char *const *b);
-DECLARE_CONST_STACK_OF(EVP_PKEY_ASN1_METHOD)
+DEFINE_CONST_STACK_OF(EVP_PKEY_ASN1_METHOD)
 static STACK_OF(EVP_PKEY_ASN1_METHOD) *app_methods = NULL;
 
 #ifdef TEST
index ed9d8d68b77af7cdee3d0846396175a91589e3a8..f138db9c81119e251a2be9966c35d5812e1e3ab7 100644 (file)
@@ -78,7 +78,7 @@ typedef struct {
     char *param_value;          /* Param value e.g. "sha1" */
 } MIME_PARAM;
 
-DECLARE_STACK_OF(MIME_PARAM)
+DEFINE_STACK_OF(MIME_PARAM)
 
 typedef struct {
     char *name;                 /* Name of line e.g. "content-type" */
@@ -86,7 +86,7 @@ typedef struct {
     STACK_OF(MIME_PARAM) *params; /* Zero or more parameters */
 } MIME_HEADER;
 
-DECLARE_STACK_OF(MIME_HEADER)
+DEFINE_STACK_OF(MIME_HEADER)
 
 static int asn1_output_data(BIO *out, BIO *data, ASN1_VALUE *val, int flags,
                             const ASN1_ITEM *it);
index ffb34f82e50982cce47080316b4ac01366d9ddd2..2f84a78e33fbb8fc23189cb4ebeba8968325d8d7 100644 (file)
@@ -87,7 +87,7 @@ struct async_job_st {
     OSSL_ASYNC_FD wake_fd;
 };
 
-DECLARE_STACK_OF(ASYNC_JOB)
+DEFINE_STACK_OF(ASYNC_JOB)
 
 struct async_pool_st {
     STACK_OF(ASYNC_JOB) *jobs;
index abc2a2741c69d88d4799975d446f94ae0ea08c11..e4b96d26eb1ae4b3dbca0a77a66bc3f11bffa5db 100644 (file)
@@ -109,7 +109,7 @@ struct CMS_ContentInfo_st {
     } d;
 };
 
-DECLARE_STACK_OF(CMS_CertificateChoices)
+DEFINE_STACK_OF(CMS_CertificateChoices)
 
 struct CMS_SignedData_st {
     long version;
index 2a0a9d452fecb250a0300a45fd11491aebb43c4c..8f775f5de7e0ed1a2d67f3becd70df7f887ac43a 100644 (file)
@@ -106,12 +106,12 @@ typedef void (ENGINE_CLEANUP_CB) (void);
 typedef struct st_engine_cleanup_item {
     ENGINE_CLEANUP_CB *cb;
 } ENGINE_CLEANUP_ITEM;
-DECLARE_STACK_OF(ENGINE_CLEANUP_ITEM)
+DEFINE_STACK_OF(ENGINE_CLEANUP_ITEM)
 void engine_cleanup_add_first(ENGINE_CLEANUP_CB *cb);
 void engine_cleanup_add_last(ENGINE_CLEANUP_CB *cb);
 
 /* We need stacks of ENGINEs for use in eng_table.c */
-DECLARE_STACK_OF(ENGINE)
+DEFINE_STACK_OF(ENGINE)
 
 /*
  * If this symbol is defined then engine_table_select(), the function that is
index dc908f804ef8c0e2c2642edc801151012841c1a6..731ae91a7adff63292a27fa63e9be582c040edc2 100644 (file)
@@ -76,7 +76,7 @@ typedef struct {
     EVP_PBE_KEYGEN *keygen;
 } EVP_PBE_CTL;
 
-DECLARE_STACK_OF(EVP_PBE_CTL)
+DEFINE_STACK_OF(EVP_PBE_CTL)
 static STACK_OF(EVP_PBE_CTL) *pbe_algs;
 
 static const EVP_PBE_CTL builtin_pbe[] = {
index e880cfa37dae3f6bee50d1fe6596594495b5a82f..aaba42aa1ff04de31e2048208506e01b289aead0 100644 (file)
@@ -69,7 +69,7 @@
 
 typedef int sk_cmp_fn_type(const char *const *a, const char *const *b);
 
-DECLARE_CONST_STACK_OF(EVP_PKEY_METHOD)
+DEFINE_CONST_STACK_OF(EVP_PKEY_METHOD)
 static STACK_OF(EVP_PKEY_METHOD) *app_pkey_methods = NULL;
 
 static const EVP_PKEY_METHOD *standard_methods[] = {
index 5bf8e1e5cd8a8edf975fe00d170ddff55e933fed..76e4b3b6a214d4d6c6c4ea9bbb7d75550d8e829b 100644 (file)
@@ -125,7 +125,7 @@ typedef struct ex_callback_st {
     CRYPTO_EX_dup *dup_func;
 } EX_CALLBACK;
 
-DECLARE_STACK_OF(EX_CALLBACK)
+DEFINE_STACK_OF(EX_CALLBACK)
 
 /*
  * The state for each class.  This could just be a typedef, but
index 2d8e045cdff6c7fe1e87a5c29e650fe28c0e5adc..31411b62be71f7a992ebc78aba9b585617fca124 100644 (file)
@@ -114,7 +114,7 @@ typedef struct {
     log_entry_type_t entry_type;
 } SCT;
 
-DECLARE_STACK_OF(SCT)
+DEFINE_STACK_OF(SCT)
 
 /*
  * Allocate new SCT.
index f337c0d8de8d39c707a28de279559e9fe76bd7c0..ec01a815bad8c27e9f2b29b7721b08b354106ff6 100644 (file)
 static double OpenSSL_MSVC5_hack = 0.0; /* and for VC1.5 */
 #endif
 
-DECLARE_STACK_OF(CRYPTO_dynlock)
+DEFINE_STACK_OF(CRYPTO_dynlock)
 
 /* real #defines in crypto.h, keep these upto date */
 static const char *const lock_names[CRYPTO_NUM_LOCKS] = {
index d7441cad824e65c00893ac3a4807360cf8b1ad76..0839feeee6aed33f44384b6680442013db8947ba 100644 (file)
@@ -34,7 +34,7 @@ typedef struct name_funcs_st {
     void (*free_func) (const char *, int, const char *);
 } NAME_FUNCS;
 
-DECLARE_STACK_OF(NAME_FUNCS)
+DEFINE_STACK_OF(NAME_FUNCS)
 
 static STACK_OF(NAME_FUNCS) *name_funcs_stack;
 
index 6e35f5746ffe0573c126e75098789671f1d7a5a3..15426fe342f1ab5a4a5e54bfdb8eaef903e7e297 100644 (file)
@@ -61,7 +61,7 @@
 #include "obj_xref.h"
 #include "e_os.h"
 
-DECLARE_STACK_OF(nid_triple)
+DEFINE_STACK_OF(nid_triple)
 
 static STACK_OF(nid_triple) *sig_app, *sigx_app;
 
index dd71a1955d1f21cb5aa4600eb09b33d5769588dc..1ffa4b01a4e4b7256af93a661965e75c6834142c 100644 (file)
@@ -83,7 +83,7 @@ typedef struct mem_object_data_st {
     int references;
 } MEM_OBJECT_DATA;
 
-DECLARE_STACK_OF(MEM_OBJECT_DATA)
+DEFINE_STACK_OF(MEM_OBJECT_DATA)
 struct mem_data_st {
     /*
      * sorted with
@@ -98,7 +98,7 @@ struct mem_data_st {
     unsigned int compute_components:1;
 };
 
-DECLARE_STACK_OF(STORE_ATTR_INFO)
+DEFINE_STACK_OF(STORE_ATTR_INFO)
 struct mem_ctx_st {
     /* The type we're searching for */
     int type;
index da28ef1cb9db172c99a80e07d146febcef351cc7..e3f915c79536c7152321ff4d2ddc05d95ff51df0 100644 (file)
@@ -144,7 +144,7 @@ struct TS_status_info_st {
     ASN1_BIT_STRING *failure_info;
 };
 
-DECLARE_STACK_OF(ASN1_UTF8STRING)
+DEFINE_STACK_OF(ASN1_UTF8STRING)
 
 /*-
  * IssuerSerial ::= SEQUENCE {
index 8310bc4701915e82522e6ce61abd2f25f3d58e3a..7e49daadfdb5a9f3ddfbf2efa311902bddee81cb 100644 (file)
@@ -90,8 +90,8 @@ typedef struct lookup_dir_st {
     STACK_OF(BY_DIR_ENTRY) *dirs;
 } BY_DIR;
 
-DECLARE_STACK_OF(BY_DIR_HASH)
-DECLARE_STACK_OF(BY_DIR_ENTRY)
+DEFINE_STACK_OF(BY_DIR_HASH)
+DEFINE_STACK_OF(BY_DIR_ENTRY)
 
 static int dir_ctrl(X509_LOOKUP *ctx, int cmd, const char *argp, long argl,
                     char **ret);
index 2895734cc1febe149c950ea9aa9ab84c99c064b5..c12b248f3afc2a83a1d69f8984f595f6a8719fb8 100644 (file)
@@ -65,7 +65,7 @@
 #include "internal/asn1_int.h"
 
 typedef STACK_OF(X509_NAME_ENTRY) STACK_OF_X509_NAME_ENTRY;
-DECLARE_STACK_OF(STACK_OF_X509_NAME_ENTRY)
+DEFINE_STACK_OF(STACK_OF_X509_NAME_ENTRY)
 
 static int x509_name_ex_d2i(ASN1_VALUE **val,
                             const unsigned char **in, long len,
index cbc94c04198e7916ffc87be1593fc7c917698f8e..b222557c52f32638d43cf4ef495b3dcf24501054 100644 (file)
@@ -59,7 +59,7 @@
 
 typedef struct X509_POLICY_DATA_st X509_POLICY_DATA;
 
-DECLARE_STACK_OF(X509_POLICY_DATA)
+DEFINE_STACK_OF(X509_POLICY_DATA)
 
 /* Internal structures */
 
index 076886974f630f32d3707f7422fba1da36d4043a..e80b376e0169fe562f1181a612b9dd401784781b 100644 (file)
@@ -157,7 +157,7 @@ extern "C" {
 # define SMIME_CRLFEOL           0x800
 # define SMIME_STREAM            0x1000
     struct X509_algor_st;
-DECLARE_STACK_OF(X509_ALGOR)
+DEFINE_STACK_OF(X509_ALGOR)
 
 # define ASN1_STRING_FLAG_BITS_LEFT 0x08/* Set if 0x07 has bits left value */
 /*
@@ -230,7 +230,7 @@ typedef struct asn1_string_table_st {
     unsigned long flags;
 } ASN1_STRING_TABLE;
 
-DECLARE_STACK_OF(ASN1_STRING_TABLE)
+DEFINE_STACK_OF(ASN1_STRING_TABLE)
 
 /* size limits: this stuff is taken straight from RFC2459 */
 
@@ -469,9 +469,9 @@ typedef const ASN1_ITEM *ASN1_ITEM_EXP (void);
                                 ASN1_STRFLGS_DUMP_UNKNOWN | \
                                 ASN1_STRFLGS_DUMP_DER)
 
-DECLARE_STACK_OF(ASN1_INTEGER)
+DEFINE_STACK_OF(ASN1_INTEGER)
 
-DECLARE_STACK_OF(ASN1_GENERALSTRING)
+DEFINE_STACK_OF(ASN1_GENERALSTRING)
 
 typedef struct asn1_type_st {
     int type;
@@ -504,7 +504,7 @@ typedef struct asn1_type_st {
     } value;
 } ASN1_TYPE;
 
-DECLARE_STACK_OF(ASN1_TYPE)
+DEFINE_STACK_OF(ASN1_TYPE)
 
 typedef STACK_OF(ASN1_TYPE) ASN1_SEQUENCE_ANY;
 
@@ -565,7 +565,7 @@ ASN1_OBJECT *d2i_ASN1_OBJECT(ASN1_OBJECT **a, const unsigned char **pp,
 
 DECLARE_ASN1_ITEM(ASN1_OBJECT)
 
-DECLARE_STACK_OF(ASN1_OBJECT)
+DEFINE_STACK_OF(ASN1_OBJECT)
 
 ASN1_STRING *ASN1_STRING_new(void);
 void ASN1_STRING_free(ASN1_STRING *a);
index f0244dc254215c2876e9baeab01b3b7e153e4165..4750b34e0c1dcd262e3a234cf16af84255c46a76 100644 (file)
@@ -964,7 +964,7 @@ DECLARE_ASN1_ITEM(BIGNUM)
 DECLARE_ASN1_ITEM(LONG)
 DECLARE_ASN1_ITEM(ZLONG)
 
-DECLARE_STACK_OF(ASN1_VALUE)
+DEFINE_STACK_OF(ASN1_VALUE)
 
 /* Functions used internally by the ASN1 code */
 
index a0a799b7dcc539c253dd2c26b4435a3293d57e27..6d6fb35f1befc7d2c6236963008cc0c9a044f73d 100644 (file)
@@ -328,7 +328,7 @@ struct bio_st {
     CRYPTO_EX_DATA ex_data;
 };
 
-DECLARE_STACK_OF(BIO)
+DEFINE_STACK_OF(BIO)
 
 typedef struct bio_f_buffer_ctx_struct {
     /*-
index 9cbfaf58cee8564c4fef41967117214314d61603..92c43a22ebc820c27362d5374af70d1d46964282 100644 (file)
@@ -76,10 +76,10 @@ typedef struct CMS_Receipt_st CMS_Receipt;
 typedef struct CMS_RecipientEncryptedKey_st CMS_RecipientEncryptedKey;
 typedef struct CMS_OtherKeyAttribute_st CMS_OtherKeyAttribute;
 
-DECLARE_STACK_OF(CMS_SignerInfo)
-DECLARE_STACK_OF(CMS_RecipientEncryptedKey)
-DECLARE_STACK_OF(CMS_RecipientInfo)
-DECLARE_STACK_OF(CMS_RevocationInfoChoice)
+DEFINE_STACK_OF(CMS_SignerInfo)
+DEFINE_STACK_OF(CMS_RecipientEncryptedKey)
+DEFINE_STACK_OF(CMS_RecipientInfo)
+DEFINE_STACK_OF(CMS_RevocationInfoChoice)
 DECLARE_ASN1_FUNCTIONS(CMS_ContentInfo)
 DECLARE_ASN1_FUNCTIONS(CMS_ReceiptRequest)
 DECLARE_ASN1_PRINT_FUNCTION(CMS_ContentInfo)
index c1114647dc20d9f5809c88957b8ae4717ef218ec..118307270f5b18457e7892fac49b9af0e1690539 100644 (file)
@@ -77,7 +77,7 @@ typedef struct {
     char *value;
 } CONF_VALUE;
 
-DECLARE_STACK_OF(CONF_VALUE)
+DEFINE_STACK_OF(CONF_VALUE)
 DECLARE_LHASH_OF(CONF_VALUE);
 
 struct conf_st;
@@ -102,8 +102,8 @@ struct conf_method_st {
 typedef struct conf_imodule_st CONF_IMODULE;
 typedef struct conf_module_st CONF_MODULE;
 
-DECLARE_STACK_OF(CONF_MODULE)
-DECLARE_STACK_OF(CONF_IMODULE)
+DEFINE_STACK_OF(CONF_MODULE)
+DEFINE_STACK_OF(CONF_IMODULE)
 
 /* DSO module function typedefs */
 typedef int conf_init_func (CONF_IMODULE *md, const CONF *cnf);
index 0d88a06f63606830f3c78dd8b28269917a04a01f..a5e5b1749b35acd4c4fe5b23c9170345e087fd95 100644 (file)
@@ -257,7 +257,7 @@ typedef struct bio_st BIO_dummy;
 struct crypto_ex_data_st {
     STACK_OF(void) *sk;
 };
-DECLARE_STACK_OF(void)
+DEFINE_STACK_OF(void)
 
 /*
  * Per class, we have a STACK of function pointers.
index 79b4c375d576b4f84d6c6e0dc7c98efe7c32c95a..3ccd79f148a73d08affb68375bea93e4659978cc 100644 (file)
@@ -95,11 +95,11 @@ extern "C" {
 
 typedef struct ocsp_cert_id_st OCSP_CERTID;
 
-DECLARE_STACK_OF(OCSP_CERTID)
+DEFINE_STACK_OF(OCSP_CERTID)
 
 typedef struct ocsp_one_request_st OCSP_ONEREQ;
 
-DECLARE_STACK_OF(OCSP_ONEREQ)
+DEFINE_STACK_OF(OCSP_ONEREQ)
 
 typedef struct ocsp_req_info_st OCSP_REQINFO;
 typedef struct ocsp_signature_st OCSP_SIGNATURE;
@@ -117,7 +117,7 @@ typedef struct ocsp_resp_bytes_st OCSP_RESPBYTES;
 # define V_OCSP_RESPID_NAME 0
 # define V_OCSP_RESPID_KEY  1
 
-DECLARE_STACK_OF(OCSP_RESPID)
+DEFINE_STACK_OF(OCSP_RESPID)
 DECLARE_ASN1_FUNCTIONS(OCSP_RESPID)
 
 typedef struct ocsp_revoked_info_st OCSP_REVOKEDINFO;
@@ -129,7 +129,7 @@ typedef struct ocsp_revoked_info_st OCSP_REVOKEDINFO;
 typedef struct ocsp_cert_status_st OCSP_CERTSTATUS;
 typedef struct ocsp_single_response_st OCSP_SINGLERESP;
 
-DECLARE_STACK_OF(OCSP_SINGLERESP)
+DEFINE_STACK_OF(OCSP_SINGLERESP)
 
 typedef struct ocsp_response_data_st OCSP_RESPDATA;
 
index ba8b9441a9a7ac9e2ae892ae77cabf8deb57aa06..d49cac7e0d91af119a6c1e77c2a162a604b72c78 100644 (file)
@@ -123,7 +123,7 @@ typedef struct {
     STACK_OF(X509_ATTRIBUTE) *attrib;
 } PKCS12_SAFEBAG;
 
-DECLARE_STACK_OF(PKCS12_SAFEBAG)
+DEFINE_STACK_OF(PKCS12_SAFEBAG)
 
 typedef struct pkcs12_bag_st {
     ASN1_OBJECT *type;
index 5d5d5c2d07a97bfea826098d2d6e36d334614c32..46fe45eacb910c14ae22deca4816292b77bf0d04 100644 (file)
@@ -100,7 +100,7 @@ typedef struct pkcs7_signer_info_st {
     EVP_PKEY *pkey;
 } PKCS7_SIGNER_INFO;
 
-DECLARE_STACK_OF(PKCS7_SIGNER_INFO)
+DEFINE_STACK_OF(PKCS7_SIGNER_INFO)
 
 typedef struct pkcs7_recip_info_st {
     ASN1_INTEGER *version;      /* version 0 */
@@ -110,7 +110,7 @@ typedef struct pkcs7_recip_info_st {
     X509 *cert;                 /* get the pub-key from this */
 } PKCS7_RECIP_INFO;
 
-DECLARE_STACK_OF(PKCS7_RECIP_INFO)
+DEFINE_STACK_OF(PKCS7_RECIP_INFO)
 
 typedef struct pkcs7_signed_st {
     ASN1_INTEGER *version;      /* version 1 */
@@ -197,7 +197,7 @@ typedef struct pkcs7_st {
     } d;
 } PKCS7;
 
-DECLARE_STACK_OF(PKCS7)
+DEFINE_STACK_OF(PKCS7)
 
 # define PKCS7_OP_SET_DETACHED_SIGNATURE 1
 # define PKCS7_OP_GET_DETACHED_SIGNATURE 2
index 9bd424ab2823e58f52d39479e223ffa0cb49f8e4..5a786590abe18a9d096f5df626559c8d08d49918 100644 (file)
@@ -88,7 +88,7 @@ extern "C" {
 
 # define STACK_OF(type) struct stack_st_##type
 
-# define SKM_DECLARE_STACK_OF(t1, t2, t3) \
+# define SKM_DEFINE_STACK_OF(t1, t2, t3) \
     STACK_OF(t1); \
     static ossl_inline int sk_##t1##_num(const STACK_OF(t1) *sk) \
     { \
@@ -183,9 +183,9 @@ extern "C" {
         return (int (*)(const t3 * const *,const t3 * const *))sk_set_cmp_func((_STACK *)sk, (int (*)(const void *a, const void *b))cmpf); \
     }
 
-# define DECLARE_SPECIAL_STACK_OF(t1, t2) SKM_DECLARE_STACK_OF(t1, t2, t2)
-# define DECLARE_STACK_OF(t) SKM_DECLARE_STACK_OF(t, t, t)
-# define DECLARE_CONST_STACK_OF(t) SKM_DECLARE_STACK_OF(t, const t, t)
+# define DEFINE_SPECIAL_STACK_OF(t1, t2) SKM_DEFINE_STACK_OF(t1, t2, t2)
+# define DEFINE_STACK_OF(t) SKM_DEFINE_STACK_OF(t, t, t)
+# define DEFINE_CONST_STACK_OF(t) SKM_DEFINE_STACK_OF(t, const t, t)
 
 /*-
  * Strings are special: normally an lhash entry will point to a single
@@ -211,14 +211,14 @@ typedef const char *OPENSSL_CSTRING;
  * chars. So, we have to implement STRING specially for STACK_OF. This is
  * dealt with in the autogenerated macros below.
  */
-DECLARE_SPECIAL_STACK_OF(OPENSSL_STRING, char)
+DEFINE_SPECIAL_STACK_OF(OPENSSL_STRING, char)
 
 /*
  * Similarly, we sometimes use a block of characters, NOT nul-terminated.
  * These should also be distinguished from "normal" stacks.
  */
 typedef void *OPENSSL_BLOCK;
-DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void)
+DEFINE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void)
 
 /*
  * This file is automatically generated by util/mkstack.pl
index 3411fe571e79fa335508651bdf508665b20aa157..b7f4519fd37f22da457ef00e580d7c9d68acb7c0 100644 (file)
@@ -83,7 +83,7 @@ typedef struct SRP_gN_cache_st {
 } SRP_gN_cache;
 
 
-DECLARE_STACK_OF(SRP_gN_cache)
+DEFINE_STACK_OF(SRP_gN_cache)
 
 typedef struct SRP_user_pwd_st {
     char *id;
@@ -94,7 +94,7 @@ typedef struct SRP_user_pwd_st {
     char *info;
 } SRP_user_pwd;
 
-DECLARE_STACK_OF(SRP_user_pwd)
+DEFINE_STACK_OF(SRP_user_pwd)
 
 typedef struct SRP_VBASE_st {
     STACK_OF(SRP_user_pwd) *users_pwd;
@@ -114,7 +114,7 @@ typedef struct SRP_gN_st {
     BIGNUM *N;
 } SRP_gN;
 
-DECLARE_STACK_OF(SRP_gN)
+DEFINE_STACK_OF(SRP_gN)
 
 SRP_VBASE *SRP_VBASE_new(char *seed_key);
 void SRP_VBASE_free(SRP_VBASE *vb);
index b2e9209752a2ff87f28864b17e597d7ac5b5c724..62325c5b35d984d62e839481a48c5db4696ab8f0 100644 (file)
@@ -325,7 +325,7 @@ typedef struct ssl_session_st SSL_SESSION;
 typedef struct tls_sigalgs_st TLS_SIGALGS;
 typedef struct ssl_conf_ctx_st SSL_CONF_CTX;
 
-DECLARE_CONST_STACK_OF(SSL_CIPHER)
+DEFINE_CONST_STACK_OF(SSL_CIPHER)
 
 DECLARE_STACK_OF(danetls_record)
 
@@ -335,7 +335,7 @@ typedef struct srtp_protection_profile_st {
     unsigned long id;
 } SRTP_PROTECTION_PROFILE;
 
-DECLARE_STACK_OF(SRTP_PROTECTION_PROFILE)
+DEFINE_STACK_OF(SRTP_PROTECTION_PROFILE)
 
 typedef int (*tls_session_ticket_ext_cb_fn) (SSL *s,
                                              const unsigned char *data,
index ffcf9810fb4ade2de4c513dc289c5b9d69009c75..cc4683e3693811c56513469c71fb8e11a7d7bd4a 100644 (file)
@@ -244,7 +244,7 @@ typedef struct STORE_OBJECT_st {
         BUF_MEM *arbitrary;
     } data;
 } STORE_OBJECT;
-DECLARE_STACK_OF(STORE_OBJECT)
+DEFINE_STACK_OF(STORE_OBJECT)
 STORE_OBJECT *STORE_OBJECT_new(void);
 void STORE_OBJECT_free(STORE_OBJECT *data);
 
index 3d4e4c0633b3a95264877ba5d804f77dda39b85c..1c54b4df9bbfdaf01a6e05aa49c643d6e2b0ad00 100644 (file)
@@ -122,7 +122,7 @@ typedef struct ESS_issuer_serial ESS_ISSUER_SERIAL;
 typedef struct ESS_cert_id ESS_CERT_ID;
 typedef struct ESS_signing_cert ESS_SIGNING_CERT;
 
-DECLARE_STACK_OF(ESS_CERT_ID)
+DEFINE_STACK_OF(ESS_CERT_ID)
 
 typedef struct TS_resp_st TS_RESP;
 
@@ -359,7 +359,7 @@ typedef int (*TS_extension_cb) (struct TS_resp_ctx *, X509_EXTENSION *,
 
 typedef struct TS_resp_ctx TS_RESP_CTX;
 
-DECLARE_STACK_OF(EVP_MD)
+DEFINE_STACK_OF(EVP_MD)
 
 /* Creates a response context that can be used for generating responses. */
 TS_RESP_CTX *TS_RESP_CTX_new(void);
index 0e49a54f3d8ee0b0da6b967c63d2cb5aa5e7baca..948ac3e77f66c69c62d262634e7b28498cc8c4d4 100644 (file)
@@ -77,7 +77,7 @@ extern "C" {
 #endif
 
 typedef OPENSSL_STRING *OPENSSL_PSTRING;
-DECLARE_SPECIAL_STACK_OF(OPENSSL_PSTRING, OPENSSL_STRING)
+DEFINE_SPECIAL_STACK_OF(OPENSSL_PSTRING, OPENSSL_STRING)
 
 typedef struct txt_db_st {
     int num_fields;
index 5cf7672a70b001cffcf7f9872af1dad18ce91cf7..3b4b372d747dcbdb6d1906ae0c24f1fe2facb6d6 100644 (file)
@@ -303,7 +303,7 @@ UI_METHOD *UI_OpenSSL(void);
  * about a string or a prompt, including test data for a verification prompt.
  */
 typedef struct ui_string_st UI_STRING;
-DECLARE_STACK_OF(UI_STRING)
+DEFINE_STACK_OF(UI_STRING)
 
 /*
  * The different types of strings that are currently supported. This is only
index 4133fc1e742c9148496343bdf4b9a4085d0c1b3c..0b00abfc2a0585b51920f29a7659e7276eee0aeb 100644 (file)
@@ -142,9 +142,9 @@ typedef struct X509_sig_st {
 
 typedef struct X509_name_entry_st X509_NAME_ENTRY;
 
-DECLARE_STACK_OF(X509_NAME_ENTRY)
+DEFINE_STACK_OF(X509_NAME_ENTRY)
 
-DECLARE_STACK_OF(X509_NAME)
+DEFINE_STACK_OF(X509_NAME)
 
 # define X509_EX_V_NETSCAPE_HACK         0x8000
 # define X509_EX_V_INIT                  0x0001
@@ -152,11 +152,11 @@ typedef struct X509_extension_st X509_EXTENSION;
 
 typedef STACK_OF(X509_EXTENSION) X509_EXTENSIONS;
 
-DECLARE_STACK_OF(X509_EXTENSION)
+DEFINE_STACK_OF(X509_EXTENSION)
 
 typedef struct x509_attributes_st X509_ATTRIBUTE;
 
-DECLARE_STACK_OF(X509_ATTRIBUTE)
+DEFINE_STACK_OF(X509_ATTRIBUTE)
 
 typedef struct X509_req_info_st X509_REQ_INFO;
 
@@ -166,7 +166,7 @@ typedef struct x509_cert_aux_st X509_CERT_AUX;
 
 typedef struct x509_cinf_st X509_CINF;
 
-DECLARE_STACK_OF(X509)
+DEFINE_STACK_OF(X509)
 
 /* This is used for a table of trust checking functions */
 
@@ -179,7 +179,7 @@ typedef struct x509_trust_st {
     void *arg2;
 } X509_TRUST;
 
-DECLARE_STACK_OF(X509_TRUST)
+DEFINE_STACK_OF(X509_TRUST)
 
 /* standard trust ids */
 
@@ -285,11 +285,11 @@ DECLARE_STACK_OF(X509_TRUST)
                         XN_FLAG_FN_LN | \
                         XN_FLAG_FN_ALIGN)
 
-DECLARE_STACK_OF(X509_REVOKED)
+DEFINE_STACK_OF(X509_REVOKED)
 
 typedef struct X509_crl_info_st X509_CRL_INFO;
 
-DECLARE_STACK_OF(X509_CRL)
+DEFINE_STACK_OF(X509_CRL)
 
 typedef struct private_key_st {
     int version;
@@ -317,7 +317,7 @@ typedef struct X509_info_st {
     int references;
 } X509_INFO;
 
-DECLARE_STACK_OF(X509_INFO)
+DEFINE_STACK_OF(X509_INFO)
 
 /*
  * The next 2 structures and their 8 routines were sent to me by Pat Richard
index e37c2f7f60d2fe7857a4bfa5dc2727eb6bd9696d..c96ab6862b603ba35ced4341ffb7e2179416b18f 100644 (file)
@@ -120,8 +120,8 @@ typedef struct x509_object_st {
 
 typedef struct x509_lookup_st X509_LOOKUP;
 
-DECLARE_STACK_OF(X509_LOOKUP)
-DECLARE_STACK_OF(X509_OBJECT)
+DEFINE_STACK_OF(X509_LOOKUP)
+DEFINE_STACK_OF(X509_OBJECT)
 
 /* This is a static that defines the function interface */
 typedef struct x509_lookup_method_st {
@@ -145,7 +145,7 @@ typedef struct x509_lookup_method_st {
 
 typedef struct X509_VERIFY_PARAM_st X509_VERIFY_PARAM;
 
-DECLARE_STACK_OF(X509_VERIFY_PARAM)
+DEFINE_STACK_OF(X509_VERIFY_PARAM)
 
 /*
  * This is used to hold everything.  It is used for all certificate
index 76d3c1f57ebfb0d5aa7a060c68d9dbbfeb7100ff..b5ea84af9bbbc6c5cf74d659962dbc0bb6573aff 100644 (file)
@@ -145,7 +145,7 @@ struct v3_ext_ctx {
 
 typedef struct v3_ext_method X509V3_EXT_METHOD;
 
-DECLARE_STACK_OF(X509V3_EXT_METHOD)
+DEFINE_STACK_OF(X509V3_EXT_METHOD)
 
 /* ext_flags values */
 # define X509V3_EXT_DYNAMIC      0x1
@@ -217,11 +217,11 @@ typedef STACK_OF(ASN1_OBJECT) EXTENDED_KEY_USAGE;
 
 typedef STACK_OF(ASN1_INTEGER) TLS_FEATURE;
 
-DECLARE_STACK_OF(GENERAL_NAME)
+DEFINE_STACK_OF(GENERAL_NAME)
 typedef STACK_OF(GENERAL_NAME) GENERAL_NAMES;
-DECLARE_STACK_OF(GENERAL_NAMES)
+DEFINE_STACK_OF(GENERAL_NAMES)
 
-DECLARE_STACK_OF(ACCESS_DESCRIPTION)
+DEFINE_STACK_OF(ACCESS_DESCRIPTION)
 
 typedef struct DIST_POINT_NAME_st {
     int type;
@@ -256,7 +256,7 @@ struct DIST_POINT_st {
 
 typedef STACK_OF(DIST_POINT) CRL_DIST_POINTS;
 
-DECLARE_STACK_OF(DIST_POINT)
+DEFINE_STACK_OF(DIST_POINT)
 
 struct AUTHORITY_KEYID_st {
     ASN1_OCTET_STRING *keyid;
@@ -271,7 +271,7 @@ typedef struct SXNET_ID_st {
     ASN1_OCTET_STRING *user;
 } SXNETID;
 
-DECLARE_STACK_OF(SXNETID)
+DEFINE_STACK_OF(SXNETID)
 
 typedef struct SXNET_st {
     ASN1_INTEGER *version;
@@ -297,7 +297,7 @@ typedef struct POLICYQUALINFO_st {
     } d;
 } POLICYQUALINFO;
 
-DECLARE_STACK_OF(POLICYQUALINFO)
+DEFINE_STACK_OF(POLICYQUALINFO)
 
 typedef struct POLICYINFO_st {
     ASN1_OBJECT *policyid;
@@ -306,14 +306,14 @@ typedef struct POLICYINFO_st {
 
 typedef STACK_OF(POLICYINFO) CERTIFICATEPOLICIES;
 
-DECLARE_STACK_OF(POLICYINFO)
+DEFINE_STACK_OF(POLICYINFO)
 
 typedef struct POLICY_MAPPING_st {
     ASN1_OBJECT *issuerDomainPolicy;
     ASN1_OBJECT *subjectDomainPolicy;
 } POLICY_MAPPING;
 
-DECLARE_STACK_OF(POLICY_MAPPING)
+DEFINE_STACK_OF(POLICY_MAPPING)
 
 typedef STACK_OF(POLICY_MAPPING) POLICY_MAPPINGS;
 
@@ -323,7 +323,7 @@ typedef struct GENERAL_SUBTREE_st {
     ASN1_INTEGER *maximum;
 } GENERAL_SUBTREE;
 
-DECLARE_STACK_OF(GENERAL_SUBTREE)
+DEFINE_STACK_OF(GENERAL_SUBTREE)
 
 struct NAME_CONSTRAINTS_st {
     STACK_OF(GENERAL_SUBTREE) *permittedSubtrees;
@@ -497,7 +497,7 @@ typedef struct x509_purpose_st {
 # define X509V3_ADD_DELETE               5L
 # define X509V3_ADD_SILENT               0x10
 
-DECLARE_STACK_OF(X509_PURPOSE)
+DEFINE_STACK_OF(X509_PURPOSE)
 
 DECLARE_ASN1_FUNCTIONS(BASIC_CONSTRAINTS)
 
@@ -760,7 +760,7 @@ int X509V3_NAME_from_section(X509_NAME *nm, STACK_OF(CONF_VALUE) *dn_sk,
                              unsigned long chtype);
 
 void X509_POLICY_NODE_print(BIO *out, X509_POLICY_NODE *node, int indent);
-DECLARE_STACK_OF(X509_POLICY_NODE)
+DEFINE_STACK_OF(X509_POLICY_NODE)
 
 #ifndef OPENSSL_NO_RFC3779
 typedef struct ASRange_st {
@@ -779,7 +779,7 @@ typedef struct ASIdOrRange_st {
 } ASIdOrRange;
 
 typedef STACK_OF(ASIdOrRange) ASIdOrRanges;
-DECLARE_STACK_OF(ASIdOrRange)
+DEFINE_STACK_OF(ASIdOrRange)
 
 # define ASIdentifierChoice_inherit              0
 # define ASIdentifierChoice_asIdsOrRanges        1
@@ -817,7 +817,7 @@ typedef struct IPAddressOrRange_st {
 } IPAddressOrRange;
 
 typedef STACK_OF(IPAddressOrRange) IPAddressOrRanges;
-DECLARE_STACK_OF(IPAddressOrRange)
+DEFINE_STACK_OF(IPAddressOrRange)
 
 # define IPAddressChoice_inherit                 0
 # define IPAddressChoice_addressesOrRanges       1
@@ -836,7 +836,7 @@ typedef struct IPAddressFamily_st {
 } IPAddressFamily;
 
 typedef STACK_OF(IPAddressFamily) IPAddrBlocks;
-DECLARE_STACK_OF(IPAddressFamily)
+DEFINE_STACK_OF(IPAddressFamily)
 
 DECLARE_ASN1_FUNCTIONS(IPAddressRange)
 DECLARE_ASN1_FUNCTIONS(IPAddressOrRange)
index 6734c4df83943cd0efa6564d8ae885eff91ee0f4..a9d4f54ef11ad29fb349ae89581ca31a8ce770e2 100644 (file)
@@ -693,7 +693,7 @@ struct ssl_comp_st {
     COMP_METHOD *method;
 };
 
-DECLARE_STACK_OF(SSL_COMP)
+DEFINE_STACK_OF(SSL_COMP)
 DECLARE_LHASH_OF(SSL_SESSION);
 
 
index 6fb577dba748b6870adce8dce3c076e1d98eee1c..c2a7ee43ea7179bbbad9613245fa9119697a5303 100755 (executable)
@@ -117,7 +117,7 @@ extern "C" {
 
 # define STACK_OF(type) struct stack_st_##type
 
-# define SKM_DECLARE_STACK_OF(t1, t2, t3) \
+# define SKM_DEFINE_STACK_OF(t1, t2, t3) \
     STACK_OF(t1); \
     static ossl_inline int sk_##t1##_num(const STACK_OF(t1) *sk) \
     { \
@@ -212,9 +212,9 @@ extern "C" {
         return (int (*)(const t3 * const *,const t3 * const *))sk_set_cmp_func((_STACK *)sk, (int (*)(const void *a, const void *b))cmpf); \
     }
 
-# define DECLARE_SPECIAL_STACK_OF(t1, t2) SKM_DECLARE_STACK_OF(t1, t2, t2)
-# define DECLARE_STACK_OF(t) SKM_DECLARE_STACK_OF(t, t, t)
-# define DECLARE_CONST_STACK_OF(t) SKM_DECLARE_STACK_OF(t, const t, t)
+# define DEFINE_SPECIAL_STACK_OF(t1, t2) SKM_DEFINE_STACK_OF(t1, t2, t2)
+# define DEFINE_STACK_OF(t) SKM_DEFINE_STACK_OF(t, t, t)
+# define DEFINE_CONST_STACK_OF(t) SKM_DEFINE_STACK_OF(t, const t, t)
 
 /*-
  * Strings are special: normally an lhash entry will point to a single
@@ -240,14 +240,14 @@ typedef const char *OPENSSL_CSTRING;
  * chars. So, we have to implement STRING specially for STACK_OF. This is
  * dealt with in the autogenerated macros below.
  */
-DECLARE_SPECIAL_STACK_OF(OPENSSL_STRING, char)
+DEFINE_SPECIAL_STACK_OF(OPENSSL_STRING, char)
 
 /*
  * Similarly, we sometimes use a block of characters, NOT nul-terminated.
  * These should also be distinguished from "normal" stacks.
  */
 typedef void *OPENSSL_BLOCK;
-DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void)
+DEFINE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void)
 
 /*
  * This file is automatically generated by util/mkstack.pl