From: Nils Larsch Date: Sun, 28 Aug 2005 22:49:57 +0000 (+0000) Subject: fix warnings when building openssl with the following compiler options: X-Git-Tag: OpenSSL_0_9_8k^2~1835 X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=8215e7a93897347a97de87b3d26fe84cc8a5b05d;p=oweals%2Fopenssl.git fix warnings when building openssl with the following compiler options: -Wmissing-prototypes -Wcomment -Wformat -Wimplicit -Wmain -Wmultichar -Wswitch -Wshadow -Wtrigraphs -Werror -Wchar-subscripts -Wstrict-prototypes -Wreturn-type -Wpointer-arith -W -Wunused -Wno-unused-parameter -Wuninitialized --- diff --git a/crypto/asn1/a_strex.c b/crypto/asn1/a_strex.c index cc6a25d4d9..45fe4bd150 100644 --- a/crypto/asn1/a_strex.c +++ b/crypto/asn1/a_strex.c @@ -223,7 +223,7 @@ static int do_buf(unsigned char *buf, int buflen, static int do_hex_dump(char_io *io_ch, void *arg, unsigned char *buf, int buflen) { - const static char hexdig[] = "0123456789ABCDEF"; + static const char hexdig[] = "0123456789ABCDEF"; unsigned char *p, *q; char hextmp[2]; if(arg) { @@ -279,7 +279,7 @@ static int do_dump(unsigned long lflags, char_io *io_ch, void *arg, ASN1_STRING * otherwise it is the number of bytes per character */ -const static signed char tag2nbyte[] = { +static const signed char tag2nbyte[] = { -1, -1, -1, -1, -1, /* 0-4 */ -1, -1, -1, -1, -1, /* 5-9 */ -1, -1, 0, -1, /* 10-13 */ diff --git a/crypto/asn1/asn1_par.c b/crypto/asn1/asn1_par.c index df247f398d..37aa6b415e 100644 --- a/crypto/asn1/asn1_par.c +++ b/crypto/asn1/asn1_par.c @@ -419,7 +419,7 @@ end: const char *ASN1_tag2str(int tag) { - const static char *tag2str[] = { + static const char *tag2str[] = { "EOC", "BOOLEAN", "INTEGER", "BIT STRING", "OCTET STRING", /* 0-4 */ "NULL", "OBJECT", "OBJECT DESCRIPTOR", "EXTERNAL", "REAL", /* 5-9 */ "ENUMERATED", "", "UTF8STRING", "", /* 10-13 */ diff --git a/crypto/bf/bf_enc.c b/crypto/bf/bf_enc.c index b380acf959..2d21d09f42 100644 --- a/crypto/bf/bf_enc.c +++ b/crypto/bf/bf_enc.c @@ -73,7 +73,7 @@ void BF_encrypt(BF_LONG *data, const BF_KEY *key) { #ifndef BF_PTR2 register BF_LONG l,r; - const register BF_LONG *p,*s; + register const BF_LONG *p,*s; p=key->P; s= &(key->S[0]); @@ -150,7 +150,7 @@ void BF_decrypt(BF_LONG *data, const BF_KEY *key) { #ifndef BF_PTR2 register BF_LONG l,r; - const register BF_LONG *p,*s; + register const BF_LONG *p,*s; p=key->P; s= &(key->S[0]); diff --git a/crypto/bn/bn.h b/crypto/bn/bn.h index b990ff2b5d..2688684b63 100644 --- a/crypto/bn/bn.h +++ b/crypto/bn/bn.h @@ -699,9 +699,11 @@ int RAND_pseudo_bytes(unsigned char *buf,int num); #define bn_check_top(a) \ do { \ const BIGNUM *_bnum2 = (a); \ - assert((_bnum2->top == 0) || \ + if (_bnum2 != NULL) { \ + assert((_bnum2->top == 0) || \ (_bnum2->d[_bnum2->top - 1] != 0)); \ - bn_pollute(_bnum2); \ + bn_pollute(_bnum2); \ + } \ } while(0) #define bn_fix_top(a) bn_check_top(a) diff --git a/crypto/bn/bn_div.c b/crypto/bn/bn_div.c index 3b4392955e..2857f44861 100644 --- a/crypto/bn/bn_div.c +++ b/crypto/bn/bn_div.c @@ -185,10 +185,8 @@ int BN_div(BIGNUM *dv, BIGNUM *rm, const BIGNUM *num, const BIGNUM *divisor, BN_ULONG d0,d1; int num_n,div_n; - if (dv) - bn_check_top(dv); - if (rm) - bn_check_top(rm); + bn_check_top(dv); + bn_check_top(rm); bn_check_top(num); bn_check_top(divisor); @@ -394,8 +392,7 @@ X) -> 0x%08X\n", BN_CTX_end(ctx); return(1); err: - if (rm) - bn_check_top(rm); + bn_check_top(rm); BN_CTX_end(ctx); return(0); } diff --git a/crypto/bn/bn_gcd.c b/crypto/bn/bn_gcd.c index 0248753f6d..f02e6fcdb4 100644 --- a/crypto/bn/bn_gcd.c +++ b/crypto/bn/bn_gcd.c @@ -488,7 +488,6 @@ BIGNUM *BN_mod_inverse(BIGNUM *in, err: if ((ret == NULL) && (in == NULL)) BN_free(R); BN_CTX_end(ctx); - if (ret) - bn_check_top(ret); + bn_check_top(ret); return(ret); } diff --git a/crypto/bn/bn_recp.c b/crypto/bn/bn_recp.c index 10fe869d28..2e8efb8dae 100644 --- a/crypto/bn/bn_recp.c +++ b/crypto/bn/bn_recp.c @@ -204,8 +204,8 @@ int BN_div_recp(BIGNUM *dv, BIGNUM *rem, const BIGNUM *m, ret=1; err: BN_CTX_end(ctx); - if(dv) bn_check_top(dv); - if(rem) bn_check_top(rem); + bn_check_top(dv); + bn_check_top(rem); return(ret); } diff --git a/crypto/bn/bn_sqr.c b/crypto/bn/bn_sqr.c index 3b4b3f0d38..270d0cd348 100644 --- a/crypto/bn/bn_sqr.c +++ b/crypto/bn/bn_sqr.c @@ -148,8 +148,8 @@ int BN_sqr(BIGNUM *r, const BIGNUM *a, BN_CTX *ctx) if (rr != r) BN_copy(r,rr); ret = 1; err: - if(rr) bn_check_top(rr); - if(tmp) bn_check_top(tmp); + bn_check_top(rr); + bn_check_top(tmp); BN_CTX_end(ctx); return(ret); } diff --git a/crypto/dso/dso_null.c b/crypto/dso/dso_null.c index fa13a7cb0f..a213f93088 100644 --- a/crypto/dso/dso_null.c +++ b/crypto/dso/dso_null.c @@ -75,8 +75,11 @@ static DSO_METHOD dso_meth_null = { NULL, /* unbind_func */ #endif NULL, /* ctrl */ + NULL, /* dso_name_converter */ + NULL, /* dso_merger */ NULL, /* init */ - NULL /* finish */ + NULL, /* finish */ + NULL /* pathbyaddr */ }; DSO_METHOD *DSO_METHOD_null(void) diff --git a/crypto/ec/ectest.c b/crypto/ec/ectest.c index 57f7eccf5f..85f63c00bb 100644 --- a/crypto/ec/ectest.c +++ b/crypto/ec/ectest.c @@ -231,7 +231,7 @@ void prime_field_tests() EC_GROUP *tmp; tmp = EC_GROUP_new(EC_GROUP_method_of(group)); if (!tmp) ABORT; - if (!EC_GROUP_copy(tmp, group)); + if (!EC_GROUP_copy(tmp, group)) ABORT; EC_GROUP_free(group); group = tmp; } @@ -834,7 +834,7 @@ void char2_field_tests() EC_GROUP *tmp; tmp = EC_GROUP_new(EC_GROUP_method_of(group)); if (!tmp) ABORT; - if (!EC_GROUP_copy(tmp, group)); + if (!EC_GROUP_copy(tmp, group)) ABORT; EC_GROUP_free(group); group = tmp; } diff --git a/crypto/engine/eng_openssl.c b/crypto/engine/eng_openssl.c index 5341daaf4e..7c139ae2ef 100644 --- a/crypto/engine/eng_openssl.c +++ b/crypto/engine/eng_openssl.c @@ -257,6 +257,7 @@ static const EVP_CIPHER test_r4_cipher= sizeof(TEST_RC4_KEY), NULL, NULL, + NULL, NULL }; static const EVP_CIPHER test_r4_40_cipher= @@ -270,6 +271,7 @@ static const EVP_CIPHER test_r4_40_cipher= sizeof(TEST_RC4_KEY), NULL, NULL, + NULL, NULL }; static int openssl_ciphers(ENGINE *e, const EVP_CIPHER **cipher, diff --git a/crypto/evp/e_null.c b/crypto/evp/e_null.c index 698a8e379c..5205259f18 100644 --- a/crypto/evp/e_null.c +++ b/crypto/evp/e_null.c @@ -76,6 +76,7 @@ static const EVP_CIPHER n_cipher= 0, NULL, NULL, + NULL, NULL }; diff --git a/crypto/evp/e_rc4.c b/crypto/evp/e_rc4.c index eadd8d4274..67af850bea 100644 --- a/crypto/evp/e_rc4.c +++ b/crypto/evp/e_rc4.c @@ -90,6 +90,7 @@ static const EVP_CIPHER r4_cipher= sizeof(EVP_RC4_KEY), NULL, NULL, + NULL, NULL }; @@ -104,6 +105,7 @@ static const EVP_CIPHER r4_40_cipher= sizeof(EVP_RC4_KEY), NULL, NULL, + NULL, NULL }; diff --git a/crypto/evp/e_xcbc_d.c b/crypto/evp/e_xcbc_d.c index cb82815a82..8832da2433 100644 --- a/crypto/evp/e_xcbc_d.c +++ b/crypto/evp/e_xcbc_d.c @@ -91,6 +91,7 @@ static const EVP_CIPHER d_xcbc_cipher= sizeof(DESX_CBC_KEY), EVP_CIPHER_set_asn1_iv, EVP_CIPHER_get_asn1_iv, + NULL, NULL }; diff --git a/crypto/objects/obj_dat.h b/crypto/objects/obj_dat.h index ae6b1794e4..c8145a69f9 100644 --- a/crypto/objects/obj_dat.h +++ b/crypto/objects/obj_dat.h @@ -825,21 +825,21 @@ static ASN1_OBJECT nid_objs[NUM_NID]={ {"DES-CFB","des-cfb",NID_des_cfb64,5,&(lvalues[192]),0}, {"DES-CBC","des-cbc",NID_des_cbc,5,&(lvalues[197]),0}, {"DES-EDE","des-ede",NID_des_ede_ecb,5,&(lvalues[202]),0}, -{"DES-EDE3","des-ede3",NID_des_ede3_ecb,0,NULL}, +{"DES-EDE3","des-ede3",NID_des_ede3_ecb,0,NULL,0}, {"IDEA-CBC","idea-cbc",NID_idea_cbc,11,&(lvalues[207]),0}, -{"IDEA-CFB","idea-cfb",NID_idea_cfb64,0,NULL}, -{"IDEA-ECB","idea-ecb",NID_idea_ecb,0,NULL}, +{"IDEA-CFB","idea-cfb",NID_idea_cfb64,0,NULL,0}, +{"IDEA-ECB","idea-ecb",NID_idea_ecb,0,NULL,0}, {"RC2-CBC","rc2-cbc",NID_rc2_cbc,8,&(lvalues[218]),0}, -{"RC2-ECB","rc2-ecb",NID_rc2_ecb,0,NULL}, -{"RC2-CFB","rc2-cfb",NID_rc2_cfb64,0,NULL}, -{"RC2-OFB","rc2-ofb",NID_rc2_ofb64,0,NULL}, +{"RC2-ECB","rc2-ecb",NID_rc2_ecb,0,NULL,0}, +{"RC2-CFB","rc2-cfb",NID_rc2_cfb64,0,NULL,0}, +{"RC2-OFB","rc2-ofb",NID_rc2_ofb64,0,NULL,0}, {"SHA","sha",NID_sha,5,&(lvalues[226]),0}, {"RSA-SHA","shaWithRSAEncryption",NID_shaWithRSAEncryption,5, &(lvalues[231]),0}, -{"DES-EDE-CBC","des-ede-cbc",NID_des_ede_cbc,0,NULL}, +{"DES-EDE-CBC","des-ede-cbc",NID_des_ede_cbc,0,NULL,0}, {"DES-EDE3-CBC","des-ede3-cbc",NID_des_ede3_cbc,8,&(lvalues[236]),0}, {"DES-OFB","des-ofb",NID_des_ofb64,5,&(lvalues[244]),0}, -{"IDEA-OFB","idea-ofb",NID_idea_ofb64,0,NULL}, +{"IDEA-OFB","idea-ofb",NID_idea_ofb64,0,NULL,0}, {"pkcs9","pkcs9",NID_pkcs9,8,&(lvalues[249]),0}, {"emailAddress","emailAddress",NID_pkcs9_emailAddress,9, &(lvalues[257]),0}, @@ -863,10 +863,10 @@ static ASN1_OBJECT nid_objs[NUM_NID]={ NID_netscape_cert_extension,8,&(lvalues[345]),0}, {"nsDataType","Netscape Data Type",NID_netscape_data_type,8, &(lvalues[353]),0}, -{"DES-EDE-CFB","des-ede-cfb",NID_des_ede_cfb64,0,NULL}, -{"DES-EDE3-CFB","des-ede3-cfb",NID_des_ede3_cfb64,0,NULL}, -{"DES-EDE-OFB","des-ede-ofb",NID_des_ede_ofb64,0,NULL}, -{"DES-EDE3-OFB","des-ede3-ofb",NID_des_ede3_ofb64,0,NULL}, +{"DES-EDE-CFB","des-ede-cfb",NID_des_ede_cfb64,0,NULL,0}, +{"DES-EDE3-CFB","des-ede3-cfb",NID_des_ede3_cfb64,0,NULL,0}, +{"DES-EDE-OFB","des-ede-ofb",NID_des_ede_ofb64,0,NULL,0}, +{"DES-EDE3-OFB","des-ede3-ofb",NID_des_ede3_ofb64,0,NULL,0}, {"SHA1","sha1",NID_sha1,5,&(lvalues[361]),0}, {"RSA-SHA1","sha1WithRSAEncryption",NID_sha1WithRSAEncryption,9, &(lvalues[366]),0}, @@ -893,7 +893,7 @@ static ASN1_OBJECT nid_objs[NUM_NID]={ {"nsComment","Netscape Comment",NID_netscape_comment,9,&(lvalues[471]),0}, {"nsCertSequence","Netscape Certificate Sequence", NID_netscape_cert_sequence,9,&(lvalues[480]),0}, -{"DESX-CBC","desx-cbc",NID_desx_cbc,0,NULL}, +{"DESX-CBC","desx-cbc",NID_desx_cbc,0,NULL,0}, {"id-ce","id-ce",NID_id_ce,2,&(lvalues[489]),0}, {"subjectKeyIdentifier","X509v3 Subject Key Identifier", NID_subject_key_identifier,3,&(lvalues[491]),0}, @@ -912,17 +912,17 @@ static ASN1_OBJECT nid_objs[NUM_NID]={ {"authorityKeyIdentifier","X509v3 Authority Key Identifier", NID_authority_key_identifier,3,&(lvalues[515]),0}, {"BF-CBC","bf-cbc",NID_bf_cbc,9,&(lvalues[518]),0}, -{"BF-ECB","bf-ecb",NID_bf_ecb,0,NULL}, -{"BF-CFB","bf-cfb",NID_bf_cfb64,0,NULL}, -{"BF-OFB","bf-ofb",NID_bf_ofb64,0,NULL}, +{"BF-ECB","bf-ecb",NID_bf_ecb,0,NULL,0}, +{"BF-CFB","bf-cfb",NID_bf_cfb64,0,NULL,0}, +{"BF-OFB","bf-ofb",NID_bf_ofb64,0,NULL,0}, {"MDC2","mdc2",NID_mdc2,4,&(lvalues[527]),0}, {"RSA-MDC2","mdc2WithRSA",NID_mdc2WithRSA,4,&(lvalues[531]),0}, -{"RC4-40","rc4-40",NID_rc4_40,0,NULL}, -{"RC2-40-CBC","rc2-40-cbc",NID_rc2_40_cbc,0,NULL}, +{"RC4-40","rc4-40",NID_rc4_40,0,NULL,0}, +{"RC2-40-CBC","rc2-40-cbc",NID_rc2_40_cbc,0,NULL,0}, {"GN","givenName",NID_givenName,3,&(lvalues[535]),0}, {"SN","surname",NID_surname,3,&(lvalues[538]),0}, {"initials","initials",NID_initials,3,&(lvalues[541]),0}, -{NULL,NULL,NID_undef,0,NULL}, +{NULL,NULL,NID_undef,0,NULL,0}, {"crlDistributionPoints","X509v3 CRL Distribution Points", NID_crl_distribution_points,3,&(lvalues[544]),0}, {"RSA-NP-MD5","md5WithRSA",NID_md5WithRSA,5,&(lvalues[547]),0}, @@ -930,23 +930,23 @@ static ASN1_OBJECT nid_objs[NUM_NID]={ {"title","title",NID_title,3,&(lvalues[555]),0}, {"description","description",NID_description,3,&(lvalues[558]),0}, {"CAST5-CBC","cast5-cbc",NID_cast5_cbc,9,&(lvalues[561]),0}, -{"CAST5-ECB","cast5-ecb",NID_cast5_ecb,0,NULL}, -{"CAST5-CFB","cast5-cfb",NID_cast5_cfb64,0,NULL}, -{"CAST5-OFB","cast5-ofb",NID_cast5_ofb64,0,NULL}, +{"CAST5-ECB","cast5-ecb",NID_cast5_ecb,0,NULL,0}, +{"CAST5-CFB","cast5-cfb",NID_cast5_cfb64,0,NULL,0}, +{"CAST5-OFB","cast5-ofb",NID_cast5_ofb64,0,NULL,0}, {"pbeWithMD5AndCast5CBC","pbeWithMD5AndCast5CBC", NID_pbeWithMD5AndCast5_CBC,9,&(lvalues[570]),0}, {"DSA-SHA1","dsaWithSHA1",NID_dsaWithSHA1,7,&(lvalues[579]),0}, -{"MD5-SHA1","md5-sha1",NID_md5_sha1,0,NULL}, +{"MD5-SHA1","md5-sha1",NID_md5_sha1,0,NULL,0}, {"RSA-SHA1-2","sha1WithRSA",NID_sha1WithRSA,5,&(lvalues[586]),0}, {"DSA","dsaEncryption",NID_dsa,7,&(lvalues[591]),0}, {"RIPEMD160","ripemd160",NID_ripemd160,5,&(lvalues[598]),0}, -{NULL,NULL,NID_undef,0,NULL}, +{NULL,NULL,NID_undef,0,NULL,0}, {"RSA-RIPEMD160","ripemd160WithRSA",NID_ripemd160WithRSA,6, &(lvalues[603]),0}, {"RC5-CBC","rc5-cbc",NID_rc5_cbc,8,&(lvalues[609]),0}, -{"RC5-ECB","rc5-ecb",NID_rc5_ecb,0,NULL}, -{"RC5-CFB","rc5-cfb",NID_rc5_cfb64,0,NULL}, -{"RC5-OFB","rc5-ofb",NID_rc5_ofb64,0,NULL}, +{"RC5-ECB","rc5-ecb",NID_rc5_ecb,0,NULL,0}, +{"RC5-CFB","rc5-cfb",NID_rc5_cfb64,0,NULL,0}, +{"RC5-OFB","rc5-ofb",NID_rc5_ofb64,0,NULL,0}, {"RLE","run length compression",NID_rle_compression,6,&(lvalues[617]),0}, {"ZLIB","zlib compression",NID_zlib_compression,6,&(lvalues[623]),0}, {"extendedKeyUsage","X509v3 Extended Key Usage",NID_ext_key_usage,3, @@ -1010,7 +1010,7 @@ static ASN1_OBJECT nid_objs[NUM_NID]={ {"id-qt-cps","Policy Qualifier CPS",NID_id_qt_cps,8,&(lvalues[958]),0}, {"id-qt-unotice","Policy Qualifier User Notice",NID_id_qt_unotice,8, &(lvalues[966]),0}, -{"RC2-64-CBC","rc2-64-cbc",NID_rc2_64_cbc,0,NULL}, +{"RC2-64-CBC","rc2-64-cbc",NID_rc2_64_cbc,0,NULL,0}, {"SMIME-CAPS","S/MIME Capabilities",NID_SMIMECapabilities,9, &(lvalues[974]),0}, {"PBE-MD2-RC2-64","pbeWithMD2AndRC2-CBC",NID_pbeWithMD2AndRC2_CBC,9, @@ -1331,7 +1331,7 @@ static ASN1_OBJECT nid_objs[NUM_NID]={ &(lvalues[2588]),0}, {"id-pda-placeOfBirth","id-pda-placeOfBirth",NID_id_pda_placeOfBirth, 8,&(lvalues[2596]),0}, -{NULL,NULL,NID_undef,0,NULL}, +{NULL,NULL,NID_undef,0,NULL,0}, {"id-pda-gender","id-pda-gender",NID_id_pda_gender,8,&(lvalues[2604]),0}, {"id-pda-countryOfCitizenship","id-pda-countryOfCitizenship", NID_id_pda_countryOfCitizenship,8,&(lvalues[2612]),0}, @@ -1563,7 +1563,7 @@ static ASN1_OBJECT nid_objs[NUM_NID]={ {"generationQualifier","generationQualifier",NID_generationQualifier, 3,&(lvalues[3877]),0}, {"pseudonym","pseudonym",NID_pseudonym,3,&(lvalues[3880]),0}, -{NULL,NULL,NID_undef,0,NULL}, +{NULL,NULL,NID_undef,0,NULL,0}, {"id-set","Secure Electronic Transactions",NID_id_set,2, &(lvalues[3883]),0}, {"set-ctype","content types",NID_set_ctype,3,&(lvalues[3885]),0}, @@ -1822,16 +1822,16 @@ static ASN1_OBJECT nid_objs[NUM_NID]={ 10,&(lvalues[4437]),0}, {"msUPN","Microsoft Universal Principal Name",NID_ms_upn,10, &(lvalues[4447]),0}, -{"AES-128-CFB1","aes-128-cfb1",NID_aes_128_cfb1,0,NULL}, -{"AES-192-CFB1","aes-192-cfb1",NID_aes_192_cfb1,0,NULL}, -{"AES-256-CFB1","aes-256-cfb1",NID_aes_256_cfb1,0,NULL}, -{"AES-128-CFB8","aes-128-cfb8",NID_aes_128_cfb8,0,NULL}, -{"AES-192-CFB8","aes-192-cfb8",NID_aes_192_cfb8,0,NULL}, -{"AES-256-CFB8","aes-256-cfb8",NID_aes_256_cfb8,0,NULL}, -{"DES-CFB1","des-cfb1",NID_des_cfb1,0,NULL}, -{"DES-CFB8","des-cfb8",NID_des_cfb8,0,NULL}, -{"DES-EDE3-CFB1","des-ede3-cfb1",NID_des_ede3_cfb1,0,NULL}, -{"DES-EDE3-CFB8","des-ede3-cfb8",NID_des_ede3_cfb8,0,NULL}, +{"AES-128-CFB1","aes-128-cfb1",NID_aes_128_cfb1,0,NULL,0}, +{"AES-192-CFB1","aes-192-cfb1",NID_aes_192_cfb1,0,NULL,0}, +{"AES-256-CFB1","aes-256-cfb1",NID_aes_256_cfb1,0,NULL,0}, +{"AES-128-CFB8","aes-128-cfb8",NID_aes_128_cfb8,0,NULL,0}, +{"AES-192-CFB8","aes-192-cfb8",NID_aes_192_cfb8,0,NULL,0}, +{"AES-256-CFB8","aes-256-cfb8",NID_aes_256_cfb8,0,NULL,0}, +{"DES-CFB1","des-cfb1",NID_des_cfb1,0,NULL,0}, +{"DES-CFB8","des-cfb8",NID_des_cfb8,0,NULL,0}, +{"DES-EDE3-CFB1","des-ede3-cfb1",NID_des_ede3_cfb1,0,NULL,0}, +{"DES-EDE3-CFB8","des-ede3-cfb8",NID_des_ede3_cfb8,0,NULL,0}, {"streetAddress","streetAddress",NID_streetAddress,3,&(lvalues[4457]),0}, {"postalCode","postalCode",NID_postalCode,3,&(lvalues[4460]),0}, {"identified-organization","identified-organization", @@ -1936,8 +1936,8 @@ static ASN1_OBJECT nid_objs[NUM_NID]={ {"SHA384","sha384",NID_sha384,9,&(lvalues[4935]),0}, {"SHA512","sha512",NID_sha512,9,&(lvalues[4944]),0}, {"SHA224","sha224",NID_sha224,9,&(lvalues[4953]),0}, -{"Oakley-EC2N-3","ipsec3",NID_ipsec3,0,NULL}, -{"Oakley-EC2N-4","ipsec4",NID_ipsec4,0,NULL}, +{"Oakley-EC2N-3","ipsec3",NID_ipsec3,0,NULL,0}, +{"Oakley-EC2N-4","ipsec4",NID_ipsec4,0,NULL,0}, {"id-ppl","id-ppl",NID_id_ppl,7,&(lvalues[4962]),0}, {"proxyCertInfo","Proxy Certificate Information",NID_proxyCertInfo,8, &(lvalues[4969]),0}, diff --git a/crypto/objects/obj_dat.pl b/crypto/objects/obj_dat.pl index d0371661f9..8a09a46ee6 100644 --- a/crypto/objects/obj_dat.pl +++ b/crypto/objects/obj_dat.pl @@ -94,7 +94,7 @@ for ($i=0; $i<$n; $i++) { if (!defined($nid{$i})) { - push(@out,"{NULL,NULL,NID_undef,0,NULL},\n"); + push(@out,"{NULL,NULL,NID_undef,0,NULL,0},\n"); } else { @@ -138,7 +138,7 @@ for ($i=0; $i<$n; $i++) } else { - $out.="0,NULL"; + $out.="0,NULL,0"; } $out.="},\n"; push(@out,$out); diff --git a/crypto/rand/randtest.c b/crypto/rand/randtest.c index ef057c2c31..9e92a70b03 100644 --- a/crypto/rand/randtest.c +++ b/crypto/rand/randtest.c @@ -65,7 +65,7 @@ /* some FIPS 140-1 random number test */ /* some simple tests */ -int main() +int main(int argc,char **argv) { unsigned char buf[2500]; int i,j,k,s,sign,nsign,err=0; diff --git a/crypto/rsa/rsa_depr.c b/crypto/rsa/rsa_depr.c index 73fa6eea90..c5582b996d 100644 --- a/crypto/rsa/rsa_depr.c +++ b/crypto/rsa/rsa_depr.c @@ -80,7 +80,7 @@ RSA *RSA_generate_key(int bits, unsigned long e_value, /* The problem is when building with 8, 16, or 32 BN_ULONG, * unsigned long can be larger */ - for (i=0; i #include -const static unsigned char zeroes[] = {0,0,0,0,0,0,0,0}; +static const unsigned char zeroes[] = {0,0,0,0,0,0,0,0}; #if defined(_MSC_VER) && defined(_ARM_) #pragma optimize("g", off) diff --git a/crypto/sha/sha256t.c b/crypto/sha/sha256t.c index 68184b2582..6b4a3bd001 100644 --- a/crypto/sha/sha256t.c +++ b/crypto/sha/sha256t.c @@ -54,7 +54,7 @@ unsigned char addenum_3[SHA224_DIGEST_LENGTH] = { 0xf0,0x3f,0x42,0x58,0x19,0x48,0xb2,0xee, 0x4e,0xe7,0xad,0x67 }; -int main () +int main (int argc,char **argv) { unsigned char md[SHA256_DIGEST_LENGTH]; int i; EVP_MD_CTX evp; diff --git a/crypto/sha/sha512t.c b/crypto/sha/sha512t.c index 4b7b3ceaa3..210041d435 100644 --- a/crypto/sha/sha512t.c +++ b/crypto/sha/sha512t.c @@ -73,7 +73,7 @@ unsigned char app_d3[SHA384_DIGEST_LENGTH] = { 0x07,0xb8,0xb3,0xdc,0x38,0xec,0xc4,0xeb, 0xae,0x97,0xdd,0xd8,0x7f,0x3d,0x89,0x85 }; -int main () +int main (int argc,char **argv) { unsigned char md[SHA512_DIGEST_LENGTH]; int i; EVP_MD_CTX evp; diff --git a/ssl/ssl_lib.c b/ssl/ssl_lib.c index 6955215c1f..9e18e776b9 100644 --- a/ssl/ssl_lib.c +++ b/ssl/ssl_lib.c @@ -138,7 +138,14 @@ SSL3_ENC_METHOD ssl3_undef_enc_method={ ssl_undefined_function, (int (*)(SSL *, unsigned char *, unsigned char *, int))ssl_undefined_function, (int (*)(SSL*, int))ssl_undefined_function, - (int (*)(SSL *, EVP_MD_CTX *, EVP_MD_CTX *, const char*, int, unsigned char *))ssl_undefined_function + (int (*)(SSL *, EVP_MD_CTX *, EVP_MD_CTX *, const char*, int, unsigned char *))ssl_undefined_function, + 0, /* finish_mac_length */ + (int (*)(SSL *, EVP_MD_CTX *, unsigned char *))ssl_undefined_function, + NULL, /* client_finished_label */ + 0, /* client_finished_label_len */ + NULL, /* server_finished_label */ + 0, /* server_finished_label_len */ + (int (*)(int))ssl_undefined_function }; int SSL_clear(SSL *s)