Commit 85885715 authored by Dr. Stephen Henson's avatar Dr. Stephen Henson
Browse files

Rename DECLARE*STACK_OF to DEFINE*STACK_OF



Applications wishing to include their own stacks now just need to include

DEFINE_STACK_OF(foo)

in a header file.

Reviewed-by: default avatarRichard Levitte <levitte@openssl.org>
parent c5e0c540
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -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
+2 −2
Original line number Diff line number Diff line
@@ -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);
+1 −1
Original line number Diff line number Diff line
@@ -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;
+1 −1
Original line number Diff line number Diff line
@@ -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;
+2 −2
Original line number Diff line number Diff line
@@ -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
Loading