diff -B -u -r org/openssl-0.9.7i/crypto/asn1/asn1_err.c modified/openssl-0.9.7i/crypto/asn1/asn1_err.c --- org/openssl-0.9.7i/crypto/asn1/asn1_err.c 2005-04-30 23:46:40.000000000 +0530 +++ modified/openssl-0.9.7i/crypto/asn1/asn1_err.c 2006-03-28 16:20:50.000000000 +0530 @@ -238,13 +238,12 @@ #endif +static int ERR_ASN1_init=1; void ERR_load_ASN1_strings(void) { - static int init=1; - - if (init) + if (ERR_ASN1_init) { - init=0; + ERR_ASN1_init=0; #ifndef OPENSSL_NO_ERR ERR_load_strings(0,ASN1_str_functs); ERR_load_strings(0,ASN1_str_reasons); @@ -252,3 +251,8 @@ } } + +void ERR_unload_ASN1_strings(void) + { + ERR_ASN1_init=1; + } diff -B -u -r org/openssl-0.9.7i/crypto/asn1/asn1.h modified/openssl-0.9.7i/crypto/asn1/asn1.h --- org/openssl-0.9.7i/crypto/asn1/asn1.h 2005-04-30 23:46:40.000000000 +0530 +++ modified/openssl-0.9.7i/crypto/asn1/asn1.h 2006-03-28 16:22:08.000000000 +0530 @@ -942,6 +942,7 @@ * made after this point may be overwritten when the script is next run. */ void ERR_load_ASN1_strings(void); +void ERR_unload_ASN1_strings(void); /* Error codes for the ASN1 functions. */ diff -B -u -r org/openssl-0.9.7i/crypto/bio/bio_err.c modified/openssl-0.9.7i/crypto/bio/bio_err.c --- org/openssl-0.9.7i/crypto/bio/bio_err.c 2005-04-12 19:17:47.000000000 +0530 +++ modified/openssl-0.9.7i/crypto/bio/bio_err.c 2006-03-28 16:33:56.000000000 +0530 @@ -140,13 +140,12 @@ #endif +static int ERR_BIO_init=1; void ERR_load_BIO_strings(void) { - static int init=1; - - if (init) + if (ERR_BIO_init) { - init=0; + ERR_BIO_init=0; #ifndef OPENSSL_NO_ERR ERR_load_strings(0,BIO_str_functs); ERR_load_strings(0,BIO_str_reasons); @@ -154,3 +153,7 @@ } } +void ERR_unload_BIO_strings(void) + { + ERR_BIO_init=1; + } diff -B -u -r org/openssl-0.9.7i/crypto/bio/bio.h modified/openssl-0.9.7i/crypto/bio/bio.h --- org/openssl-0.9.7i/crypto/bio/bio.h 2004-05-11 18:15:04.000000000 +0530 +++ modified/openssl-0.9.7i/crypto/bio/bio.h 2006-03-28 16:33:37.000000000 +0530 @@ -622,6 +622,7 @@ * made after this point may be overwritten when the script is next run. */ void ERR_load_BIO_strings(void); +void ERR_unload_BIO_strings(void); /* Error codes for the BIO functions. */ diff -B -u -r org/openssl-0.9.7i/crypto/bn/bn_err.c modified/openssl-0.9.7i/crypto/bn/bn_err.c --- org/openssl-0.9.7i/crypto/bn/bn_err.c 2005-05-16 06:56:02.000000000 +0530 +++ modified/openssl-0.9.7i/crypto/bn/bn_err.c 2006-03-28 16:38:10.000000000 +0530 @@ -123,13 +123,12 @@ #endif +static int ERR_BN_init=1; void ERR_load_BN_strings(void) { - static int init=1; - - if (init) + if (ERR_BN_init) { - init=0; + ERR_BN_init=0; #ifndef OPENSSL_NO_ERR ERR_load_strings(0,BN_str_functs); ERR_load_strings(0,BN_str_reasons); @@ -137,3 +136,7 @@ } } +void ERR_unload_BN_strings(void) + { + ERR_BN_init=1; + } diff -B -u -r org/openssl-0.9.7i/crypto/bn/bn.h modified/openssl-0.9.7i/crypto/bn/bn.h --- org/openssl-0.9.7i/crypto/bn/bn.h 2005-05-31 18:07:57.000000000 +0530 +++ modified/openssl-0.9.7i/crypto/bn/bn.h 2006-03-28 16:38:47.000000000 +0530 @@ -527,6 +527,7 @@ * made after this point may be overwritten when the script is next run. */ void ERR_load_BN_strings(void); +void ERR_unload_BN_strings(void); /* Error codes for the BN functions. */ diff -B -u -r org/openssl-0.9.7i/crypto/buffer/buf_err.c modified/openssl-0.9.7i/crypto/buffer/buf_err.c --- org/openssl-0.9.7i/crypto/buffer/buf_err.c 2005-04-12 19:17:48.000000000 +0530 +++ modified/openssl-0.9.7i/crypto/buffer/buf_err.c 2006-03-28 16:40:08.000000000 +0530 @@ -83,13 +83,12 @@ #endif +static int ERR_BUF_init=1; void ERR_load_BUF_strings(void) { - static int init=1; - - if (init) + if (ERR_BUF_init) { - init=0; + ERR_BUF_init=0; #ifndef OPENSSL_NO_ERR ERR_load_strings(0,BUF_str_functs); ERR_load_strings(0,BUF_str_reasons); @@ -97,3 +96,7 @@ } } +void ERR_unload_BUF_strings(void) + { + ERR_BUF_init=1; + } diff -B -u -r org/openssl-0.9.7i/crypto/buffer/buffer.h modified/openssl-0.9.7i/crypto/buffer/buffer.h --- org/openssl-0.9.7i/crypto/buffer/buffer.h 2002-11-14 21:28:01.000000000 +0530 +++ modified/openssl-0.9.7i/crypto/buffer/buffer.h 2006-03-28 16:40:35.000000000 +0530 @@ -89,6 +89,7 @@ * made after this point may be overwritten when the script is next run. */ void ERR_load_BUF_strings(void); +void ERR_unload_BUF_strings(void); /* Error codes for the BUF functions. */ diff -B -u -r org/openssl-0.9.7i/crypto/comp/comp_err.c modified/openssl-0.9.7i/crypto/comp/comp_err.c --- org/openssl-0.9.7i/crypto/comp/comp_err.c 2001-02-19 21:34:58.000000000 +0530 +++ modified/openssl-0.9.7i/crypto/comp/comp_err.c 2006-03-28 17:00:46.000000000 +0530 @@ -76,13 +76,12 @@ #endif +static int ERR_COMP_init=1; void ERR_load_COMP_strings(void) { - static int init=1; - - if (init) + if (ERR_COMP_init) { - init=0; + ERR_COMP_init=0; #ifndef OPENSSL_NO_ERR ERR_load_strings(ERR_LIB_COMP,COMP_str_functs); ERR_load_strings(ERR_LIB_COMP,COMP_str_reasons); @@ -90,3 +89,7 @@ } } +void ERR_unload_COMP_strings(void) + { + ERR_COMP_init=1; + } diff -B -u -r org/openssl-0.9.7i/crypto/comp/comp.h modified/openssl-0.9.7i/crypto/comp/comp.h --- org/openssl-0.9.7i/crypto/comp/comp.h 2002-01-04 18:42:08.000000000 +0530 +++ modified/openssl-0.9.7i/crypto/comp/comp.h 2006-03-28 17:01:04.000000000 +0530 @@ -46,6 +46,7 @@ * made after this point may be overwritten when the script is next run. */ void ERR_load_COMP_strings(void); +void ERR_unload_COMP_strings(void); /* Error codes for the COMP functions. */ diff -B -u -r org/openssl-0.9.7i/crypto/conf/conf_err.c modified/openssl-0.9.7i/crypto/conf/conf_err.c --- org/openssl-0.9.7i/crypto/conf/conf_err.c 2005-04-12 19:17:49.000000000 +0530 +++ modified/openssl-0.9.7i/crypto/conf/conf_err.c 2006-03-28 17:02:01.000000000 +0530 @@ -114,13 +114,12 @@ #endif +static int ERR_CONF_init=1; void ERR_load_CONF_strings(void) { - static int init=1; - - if (init) + if (ERR_CONF_init) { - init=0; + ERR_CONF_init=0; #ifndef OPENSSL_NO_ERR ERR_load_strings(0,CONF_str_functs); ERR_load_strings(0,CONF_str_reasons); @@ -128,3 +127,7 @@ } } +void ERR_unload_CONF_strings(void) + { + ERR_CONF_init=1; + } diff -B -u -r org/openssl-0.9.7i/crypto/conf/conf.h modified/openssl-0.9.7i/crypto/conf/conf.h --- org/openssl-0.9.7i/crypto/conf/conf.h 2002-06-13 23:08:51.000000000 +0530 +++ modified/openssl-0.9.7i/crypto/conf/conf.h 2006-03-28 17:04:54.000000000 +0530 @@ -203,6 +203,7 @@ * made after this point may be overwritten when the script is next run. */ void ERR_load_CONF_strings(void); +void ERR_unload_CONF_strings(void); /* Error codes for the CONF functions. */ diff -B -u -r org/openssl-0.9.7i/crypto/cpt_err.c modified/openssl-0.9.7i/crypto/cpt_err.c --- org/openssl-0.9.7i/crypto/cpt_err.c 2005-04-12 19:17:46.000000000 +0530 +++ modified/openssl-0.9.7i/crypto/cpt_err.c 2006-03-28 17:05:53.000000000 +0530 @@ -90,13 +90,12 @@ #endif +static int ERR_CRYPTO_init=1; void ERR_load_CRYPTO_strings(void) { - static int init=1; - - if (init) + if (ERR_CRYPTO_init) { - init=0; + ERR_CRYPTO_init=0; #ifndef OPENSSL_NO_ERR ERR_load_strings(0,CRYPTO_str_functs); ERR_load_strings(0,CRYPTO_str_reasons); @@ -104,3 +103,7 @@ } } +void ERR_unload_CRYPTO_strings(void) + { + ERR_CRYPTO_init=1; + } diff -B -u -r org/openssl-0.9.7i/crypto/crypto.h modified/openssl-0.9.7i/crypto/crypto.h --- org/openssl-0.9.7i/crypto/crypto.h 2005-05-09 01:22:13.000000000 +0530 +++ modified/openssl-0.9.7i/crypto/crypto.h 2006-03-28 17:07:23.000000000 +0530 @@ -495,6 +495,7 @@ * made after this point may be overwritten when the script is next run. */ void ERR_load_CRYPTO_strings(void); +void ERR_unload_CRYPTO_strings(void); /* Error codes for the CRYPTO functions. */ diff -B -u -r org/openssl-0.9.7i/crypto/dh/dh_err.c modified/openssl-0.9.7i/crypto/dh/dh_err.c --- org/openssl-0.9.7i/crypto/dh/dh_err.c 2005-04-12 19:17:49.000000000 +0530 +++ modified/openssl-0.9.7i/crypto/dh/dh_err.c 2006-03-28 17:16:43.000000000 +0530 @@ -88,13 +88,12 @@ #endif +static int ERR_DH_init=1; void ERR_load_DH_strings(void) { - static int init=1; - - if (init) + if (ERR_DH_init) { - init=0; + ERR_DH_init=0; #ifndef OPENSSL_NO_ERR ERR_load_strings(0,DH_str_functs); ERR_load_strings(0,DH_str_reasons); @@ -102,3 +101,7 @@ } } +void ERR_unload_DH_strings(void) + { + ERR_DH_init=1; + } diff -B -u -r org/openssl-0.9.7i/crypto/dh/dh.h modified/openssl-0.9.7i/crypto/dh/dh.h --- org/openssl-0.9.7i/crypto/dh/dh.h 2005-05-16 06:56:03.000000000 +0530 +++ modified/openssl-0.9.7i/crypto/dh/dh.h 2006-03-28 17:08:28.000000000 +0530 @@ -193,6 +193,7 @@ * made after this point may be overwritten when the script is next run. */ void ERR_load_DH_strings(void); +void ERR_unload_DH_strings(void); /* Error codes for the DH functions. */ diff -B -u -r org/openssl-0.9.7i/crypto/dsa/dsa_err.c modified/openssl-0.9.7i/crypto/dsa/dsa_err.c --- org/openssl-0.9.7i/crypto/dsa/dsa_err.c 2005-04-12 19:17:50.000000000 +0530 +++ modified/openssl-0.9.7i/crypto/dsa/dsa_err.c 2006-03-28 17:09:25.000000000 +0530 @@ -96,13 +96,12 @@ #endif +static int ERR_DSA_init=1; void ERR_load_DSA_strings(void) { - static int init=1; - - if (init) + if (ERR_DSA_init) { - init=0; + ERR_DSA_init=0; #ifndef OPENSSL_NO_ERR ERR_load_strings(0,DSA_str_functs); ERR_load_strings(0,DSA_str_reasons); @@ -110,3 +109,7 @@ } } +void ERR_unload_DSA_strings(void) + { + ERR_DSA_init=1; + } diff -B -u -r org/openssl-0.9.7i/crypto/dsa/dsa.h modified/openssl-0.9.7i/crypto/dsa/dsa.h --- org/openssl-0.9.7i/crypto/dsa/dsa.h 2005-05-16 06:56:04.000000000 +0530 +++ modified/openssl-0.9.7i/crypto/dsa/dsa.h 2006-03-28 17:09:45.000000000 +0530 @@ -232,6 +232,7 @@ * made after this point may be overwritten when the script is next run. */ void ERR_load_DSA_strings(void); +void ERR_unload_DSA_strings(void); /* Error codes for the DSA functions. */ diff -B -u -r org/openssl-0.9.7i/crypto/dso/dso_err.c modified/openssl-0.9.7i/crypto/dso/dso_err.c --- org/openssl-0.9.7i/crypto/dso/dso_err.c 2005-04-12 19:17:50.000000000 +0530 +++ modified/openssl-0.9.7i/crypto/dso/dso_err.c 2006-03-28 17:10:44.000000000 +0530 @@ -123,13 +123,12 @@ #endif +static int ERR_DSO_init=1; void ERR_load_DSO_strings(void) { - static int init=1; - - if (init) + if (ERR_DSO_init) { - init=0; + ERR_DSO_init=0; #ifndef OPENSSL_NO_ERR ERR_load_strings(0,DSO_str_functs); ERR_load_strings(0,DSO_str_reasons); @@ -137,3 +136,7 @@ } } +void ERR_unload_DSO_strings(void) + { + ERR_DSO_init=1; + } diff -B -u -r org/openssl-0.9.7i/crypto/dso/dso.h modified/openssl-0.9.7i/crypto/dso/dso.h --- org/openssl-0.9.7i/crypto/dso/dso.h 2001-12-18 00:58:05.000000000 +0530 +++ modified/openssl-0.9.7i/crypto/dso/dso.h 2006-03-28 17:11:00.000000000 +0530 @@ -266,6 +266,7 @@ * made after this point may be overwritten when the script is next run. */ void ERR_load_DSO_strings(void); +void ERR_unload_DSO_strings(void); /* Error codes for the DSO functions. */ diff -B -u -r org/openssl-0.9.7i/crypto/ec/ec_err.c modified/openssl-0.9.7i/crypto/ec/ec_err.c --- org/openssl-0.9.7i/crypto/ec/ec_err.c 2005-04-12 19:17:51.000000000 +0530 +++ modified/openssl-0.9.7i/crypto/ec/ec_err.c 2006-03-28 17:11:46.000000000 +0530 @@ -137,13 +137,12 @@ #endif +static int ERR_EC_init=1; void ERR_load_EC_strings(void) { - static int init=1; - - if (init) + if (ERR_EC_init) { - init=0; + ERR_EC_init=0; #ifndef OPENSSL_NO_ERR ERR_load_strings(0,EC_str_functs); ERR_load_strings(0,EC_str_reasons); @@ -151,3 +150,7 @@ } } +void ERR_unload_EC_strings(void) + { + ERR_EC_init=1; + } diff -B -u -r org/openssl-0.9.7i/crypto/ec/ec.h modified/openssl-0.9.7i/crypto/ec/ec.h --- org/openssl-0.9.7i/crypto/ec/ec.h 2003-02-06 23:30:20.000000000 +0530 +++ modified/openssl-0.9.7i/crypto/ec/ec.h 2006-03-28 17:12:10.000000000 +0530 @@ -173,6 +173,7 @@ * made after this point may be overwritten when the script is next run. */ void ERR_load_EC_strings(void); +void ERR_unload_EC_strings(void); /* Error codes for the EC functions. */ diff -B -u -r org/openssl-0.9.7i/crypto/engine/eng_err.c modified/openssl-0.9.7i/crypto/engine/eng_err.c --- org/openssl-0.9.7i/crypto/engine/eng_err.c 2005-04-12 19:17:51.000000000 +0530 +++ modified/openssl-0.9.7i/crypto/engine/eng_err.c 2006-03-28 17:12:58.000000000 +0530 @@ -154,13 +154,12 @@ #endif +static int ERR_ENGINE_init=1; void ERR_load_ENGINE_strings(void) { - static int init=1; - - if (init) + if (ERR_ENGINE_init) { - init=0; + ERR_ENGINE_init=0; #ifndef OPENSSL_NO_ERR ERR_load_strings(0,ENGINE_str_functs); ERR_load_strings(0,ENGINE_str_reasons); @@ -168,3 +167,7 @@ } } +void ERR_unload_ENGINE_strings(void) + { + ERR_ENGINE_init=1; + } diff -B -u -r org/openssl-0.9.7i/crypto/engine/engine.h modified/openssl-0.9.7i/crypto/engine/engine.h --- org/openssl-0.9.7i/crypto/engine/engine.h 2003-11-29 15:55:41.000000000 +0530 +++ modified/openssl-0.9.7i/crypto/engine/engine.h 2006-03-28 17:14:07.000000000 +0530 @@ -642,6 +642,7 @@ * made after this point may be overwritten when the script is next run. */ void ERR_load_ENGINE_strings(void); +void ERR_unload_ENGINE_strings(void); /* Error codes for the ENGINE functions. */ diff -B -u -r org/openssl-0.9.7i/crypto/err/err_all.c modified/openssl-0.9.7i/crypto/err/err_all.c --- org/openssl-0.9.7i/crypto/err/err_all.c 2004-05-11 18:15:21.000000000 +0530 +++ modified/openssl-0.9.7i/crypto/err/err_all.c 2006-03-29 16:42:42.000000000 +0530 @@ -89,12 +89,11 @@ #include #include +static int ERR_crypto_done=0; void ERR_load_crypto_strings(void) { - static int done=0; - - if (done) return; - done=1; + if (ERR_crypto_done) return; + ERR_crypto_done=1; #ifndef OPENSSL_NO_ERR ERR_load_ERR_strings(); /* include error strings for SYSerr */ ERR_load_BN_strings(); @@ -135,3 +134,47 @@ ERR_load_FIPS_strings(); #endif } + + +void ERR_unload_crypto_strings(void) + { + ERR_crypto_done=0; +#ifndef OPENSSL_NO_ERR + //ERR_unload_ERR_strings(); + ERR_unload_BN_strings(); +#ifndef OPENSSL_NO_RSA + ERR_unload_RSA_strings(); +#endif +#ifndef OPENSSL_NO_DH + ERR_unload_DH_strings(); +#endif + ERR_unload_EVP_strings(); + ERR_unload_BUF_strings(); + ERR_unload_OBJ_strings(); + ERR_unload_PEM_strings(); +#ifndef OPENSSL_NO_DSA + ERR_unload_DSA_strings(); +#endif + ERR_unload_X509_strings(); + ERR_unload_ASN1_strings(); + ERR_unload_CONF_strings(); + ERR_unload_CRYPTO_strings(); +#ifndef OPENSSL_NO_EC + ERR_unload_EC_strings(); +#endif + ERR_unload_BIO_strings(); + ERR_unload_PKCS7_strings(); + ERR_unload_X509V3_strings(); + ERR_unload_PKCS12_strings(); + ERR_unload_RAND_strings(); + ERR_unload_DSO_strings(); +#ifndef OPENSSL_NO_ENGINE + ERR_unload_ENGINE_strings(); +#endif + ERR_unload_OCSP_strings(); + ERR_unload_UI_strings(); +#endif +#ifdef OPENSSL_FIPS + ERR_unload_FIPS_strings(); +#endif + } diff -B -u -r org/openssl-0.9.7i/crypto/err/err.c modified/openssl-0.9.7i/crypto/err/err.c --- org/openssl-0.9.7i/crypto/err/err.c 2005-04-12 19:00:45.000000000 +0530 +++ modified/openssl-0.9.7i/crypto/err/err.c 2006-03-28 16:13:45.000000000 +0530 @@ -647,6 +647,7 @@ void ERR_free_strings(void) { + ERR_unload_crypto_strings(); err_fns_check(); ERRFN(err_del)(); } diff -B -u -r org/openssl-0.9.7i/crypto/err/err.h modified/openssl-0.9.7i/crypto/err/err.h --- org/openssl-0.9.7i/crypto/err/err.h 2004-12-14 04:18:00.000000000 +0530 +++ modified/openssl-0.9.7i/crypto/err/err.h 2006-03-28 17:50:21.000000000 +0530 @@ -272,7 +272,9 @@ void ERR_load_strings(int lib,ERR_STRING_DATA str[]); void ERR_unload_strings(int lib,ERR_STRING_DATA str[]); void ERR_load_ERR_strings(void); +void ERR_unload_ERR_strings(void); void ERR_load_crypto_strings(void); +void ERR_unload_crypto_strings(void); void ERR_free_strings(void); void ERR_remove_state(unsigned long pid); /* if zero we look it up */ diff -B -u -r org/openssl-0.9.7i/crypto/evp/evp_err.c modified/openssl-0.9.7i/crypto/evp/evp_err.c --- org/openssl-0.9.7i/crypto/evp/evp_err.c 2005-04-12 19:17:52.000000000 +0530 +++ modified/openssl-0.9.7i/crypto/evp/evp_err.c 2006-03-28 17:14:54.000000000 +0530 @@ -155,13 +155,12 @@ #endif +static int ERR_EVP_init=1; void ERR_load_EVP_strings(void) { - static int init=1; - - if (init) + if (ERR_EVP_init) { - init=0; + ERR_EVP_init=0; #ifndef OPENSSL_NO_ERR ERR_load_strings(0,EVP_str_functs); ERR_load_strings(0,EVP_str_reasons); @@ -169,3 +168,7 @@ } } +void ERR_unload_EVP_strings(void) + { + ERR_EVP_init=1; + } diff -B -u -r org/openssl-0.9.7i/crypto/evp/evp.h modified/openssl-0.9.7i/crypto/evp/evp.h --- org/openssl-0.9.7i/crypto/evp/evp.h 2005-10-13 02:09:22.000000000 +0530 +++ modified/openssl-0.9.7i/crypto/evp/evp.h 2006-03-28 17:15:16.000000000 +0530 @@ -880,6 +880,7 @@ * made after this point may be overwritten when the script is next run. */ void ERR_load_EVP_strings(void); +void ERR_unload_EVP_strings(void); /* Error codes for the EVP functions. */ diff -B -u -r org/openssl-0.9.7i/crypto/objects/objects.h modified/openssl-0.9.7i/crypto/objects/objects.h --- org/openssl-0.9.7i/crypto/objects/objects.h 2004-12-05 06:34:38.000000000 +0530 +++ modified/openssl-0.9.7i/crypto/objects/objects.h 2006-03-28 17:21:12.000000000 +0530 @@ -1022,6 +1022,7 @@ * made after this point may be overwritten when the script is next run. */ void ERR_load_OBJ_strings(void); +void ERR_unload_OBJ_strings(void); /* Error codes for the OBJ functions. */ diff -B -u -r org/openssl-0.9.7i/crypto/objects/obj_err.c modified/openssl-0.9.7i/crypto/objects/obj_err.c --- org/openssl-0.9.7i/crypto/objects/obj_err.c 2005-04-12 19:17:53.000000000 +0530 +++ modified/openssl-0.9.7i/crypto/objects/obj_err.c 2006-03-28 17:20:33.000000000 +0530 @@ -89,13 +89,12 @@ #endif +static int ERR_OBJ_init=1; void ERR_load_OBJ_strings(void) { - static int init=1; - - if (init) + if (ERR_OBJ_init) { - init=0; + ERR_OBJ_init=0; #ifndef OPENSSL_NO_ERR ERR_load_strings(0,OBJ_str_functs); ERR_load_strings(0,OBJ_str_reasons); @@ -103,3 +102,7 @@ } } +void ERR_unload_OBJ_strings(void) + { + ERR_OBJ_init=1; + } diff -B -u -r org/openssl-0.9.7i/crypto/ocsp/ocsp_err.c modified/openssl-0.9.7i/crypto/ocsp/ocsp_err.c --- org/openssl-0.9.7i/crypto/ocsp/ocsp_err.c 2005-04-12 19:17:53.000000000 +0530 +++ modified/openssl-0.9.7i/crypto/ocsp/ocsp_err.c 2006-03-28 17:22:17.000000000 +0530 @@ -127,13 +127,12 @@ #endif +static int ERR_OCSP_init=1; void ERR_load_OCSP_strings(void) { - static int init=1; - - if (init) + if (ERR_OCSP_init) { - init=0; + ERR_OCSP_init=0; #ifndef OPENSSL_NO_ERR ERR_load_strings(0,OCSP_str_functs); ERR_load_strings(0,OCSP_str_reasons); @@ -141,3 +140,7 @@ } } +void ERR_unload_OCSP_strings(void) + { + ERR_OCSP_init=1; + } diff -B -u -r org/openssl-0.9.7i/crypto/ocsp/ocsp.h modified/openssl-0.9.7i/crypto/ocsp/ocsp.h --- org/openssl-0.9.7i/crypto/ocsp/ocsp.h 2001-12-18 00:52:06.000000000 +0530 +++ modified/openssl-0.9.7i/crypto/ocsp/ocsp.h 2006-03-28 17:22:42.000000000 +0530 @@ -559,6 +559,7 @@ * made after this point may be overwritten when the script is next run. */ void ERR_load_OCSP_strings(void); +void ERR_unload_OCSP_strings(void); /* Error codes for the OCSP functions. */ diff -B -u -r org/openssl-0.9.7i/crypto/pem/pem_err.c modified/openssl-0.9.7i/crypto/pem/pem_err.c --- org/openssl-0.9.7i/crypto/pem/pem_err.c 2005-04-12 19:17:54.000000000 +0530 +++ modified/openssl-0.9.7i/crypto/pem/pem_err.c 2006-03-28 17:24:02.000000000 +0530 @@ -119,13 +119,12 @@ #endif +static ERR_PEM_init=1; void ERR_load_PEM_strings(void) { - static int init=1; - - if (init) + if (ERR_PEM_init) { - init=0; + ERR_PEM_init=0; #ifndef OPENSSL_NO_ERR ERR_load_strings(0,PEM_str_functs); ERR_load_strings(0,PEM_str_reasons); @@ -133,3 +132,7 @@ } } +void ERR_unload_PEM_strings(void) + { + ERR_PEM_init=1; + } diff -B -u -r org/openssl-0.9.7i/crypto/pem/pem.h modified/openssl-0.9.7i/crypto/pem/pem.h --- org/openssl-0.9.7i/crypto/pem/pem.h 2002-11-12 18:52:41.000000000 +0530 +++ modified/openssl-0.9.7i/crypto/pem/pem.h 2006-03-28 17:24:18.000000000 +0530 @@ -620,6 +620,7 @@ * made after this point may be overwritten when the script is next run. */ void ERR_load_PEM_strings(void); +void ERR_unload_PEM_strings(void); /* Error codes for the PEM functions. */ diff -B -u -r org/openssl-0.9.7i/crypto/pkcs12/pk12err.c modified/openssl-0.9.7i/crypto/pkcs12/pk12err.c --- org/openssl-0.9.7i/crypto/pkcs12/pk12err.c 2005-06-30 17:07:36.000000000 +0530 +++ modified/openssl-0.9.7i/crypto/pkcs12/pk12err.c 2006-03-28 17:28:26.000000000 +0530 @@ -130,13 +130,12 @@ #endif +static int ERR_PKCS12_init=1; void ERR_load_PKCS12_strings(void) { - static int init=1; - - if (init) + if (ERR_PKCS12_init) { - init=0; + ERR_PKCS12_init=0; #ifndef OPENSSL_NO_ERR ERR_load_strings(0,PKCS12_str_functs); ERR_load_strings(0,PKCS12_str_reasons); @@ -144,3 +143,7 @@ } } +void ERR_unload_PKCS12_strings(void) + { + ERR_PKCS12_init=1; + } diff -B -u -r org/openssl-0.9.7i/crypto/pkcs12/pkcs12.h modified/openssl-0.9.7i/crypto/pkcs12/pkcs12.h --- org/openssl-0.9.7i/crypto/pkcs12/pkcs12.h 2005-06-30 17:07:36.000000000 +0530 +++ modified/openssl-0.9.7i/crypto/pkcs12/pkcs12.h 2006-03-28 17:28:57.000000000 +0530 @@ -260,6 +260,7 @@ * made after this point may be overwritten when the script is next run. */ void ERR_load_PKCS12_strings(void); +void ERR_unload_PKCS12_strings(void); /* Error codes for the PKCS12 functions. */ diff -B -u -r org/openssl-0.9.7i/crypto/pkcs7/pkcs7err.c modified/openssl-0.9.7i/crypto/pkcs7/pkcs7err.c --- org/openssl-0.9.7i/crypto/pkcs7/pkcs7err.c 2005-04-12 19:17:55.000000000 +0530 +++ modified/openssl-0.9.7i/crypto/pkcs7/pkcs7err.c 2006-03-29 11:24:45.000000000 +0530 @@ -148,13 +148,12 @@ #endif +static int ERR_PKCS7_init=1; void ERR_load_PKCS7_strings(void) { - static int init=1; - - if (init) + if (ERR_PKCS7_init) { - init=0; + ERR_PKCS7_init=0; #ifndef OPENSSL_NO_ERR ERR_load_strings(0,PKCS7_str_functs); ERR_load_strings(0,PKCS7_str_reasons); @@ -162,3 +161,7 @@ } } +void ERR_unload_PKCS7_strings(void) + { + ERR_PKCS7_init=1; + } diff -B -u -r org/openssl-0.9.7i/crypto/pkcs7/pkcs7.h modified/openssl-0.9.7i/crypto/pkcs7/pkcs7.h --- org/openssl-0.9.7i/crypto/pkcs7/pkcs7.h 2003-06-02 02:15:44.000000000 +0530 +++ modified/openssl-0.9.7i/crypto/pkcs7/pkcs7.h 2006-03-28 17:30:20.000000000 +0530 @@ -370,6 +370,7 @@ * made after this point may be overwritten when the script is next run. */ void ERR_load_PKCS7_strings(void); +void ERR_unload_PKCS7_strings(void); /* Error codes for the PKCS7 functions. */ diff -B -u -r org/openssl-0.9.7i/crypto/rand/rand_err.c modified/openssl-0.9.7i/crypto/rand/rand_err.c --- org/openssl-0.9.7i/crypto/rand/rand_err.c 2005-04-12 19:17:55.000000000 +0530 +++ modified/openssl-0.9.7i/crypto/rand/rand_err.c 2006-03-28 17:31:08.000000000 +0530 @@ -89,13 +89,12 @@ #endif +static int ERR_RAND_init=1; void ERR_load_RAND_strings(void) { - static int init=1; - - if (init) + if (ERR_RAND_init) { - init=0; + ERR_RAND_init=0; #ifndef OPENSSL_NO_ERR ERR_load_strings(0,RAND_str_functs); ERR_load_strings(0,RAND_str_reasons); @@ -103,3 +102,7 @@ } } +void ERR_unload_RAND_strings(void) + { + ERR_RAND_init=1; + } diff -B -u -r org/openssl-0.9.7i/crypto/rand/rand.h modified/openssl-0.9.7i/crypto/rand/rand.h --- org/openssl-0.9.7i/crypto/rand/rand.h 2004-08-10 14:39:03.000000000 +0530 +++ modified/openssl-0.9.7i/crypto/rand/rand.h 2006-03-28 17:31:32.000000000 +0530 @@ -121,6 +121,7 @@ * made after this point may be overwritten when the script is next run. */ void ERR_load_RAND_strings(void); +void ERR_unload_RAND_strings(void); /* Error codes for the RAND functions. */ diff -B -u -r org/openssl-0.9.7i/crypto/rsa/rsa_err.c modified/openssl-0.9.7i/crypto/rsa/rsa_err.c --- org/openssl-0.9.7i/crypto/rsa/rsa_err.c 2005-06-02 23:37:16.000000000 +0530 +++ modified/openssl-0.9.7i/crypto/rsa/rsa_err.c 2006-03-28 17:32:30.000000000 +0530 @@ -148,13 +148,12 @@ #endif +static int ERR_RSA_init=1; void ERR_load_RSA_strings(void) { - static int init=1; - - if (init) + if (ERR_RSA_init) { - init=0; + ERR_RSA_init=0; #ifndef OPENSSL_NO_ERR ERR_load_strings(0,RSA_str_functs); ERR_load_strings(0,RSA_str_reasons); @@ -162,3 +161,7 @@ } } +void ERR_unload_RSA_strings(void) + { + ERR_RSA_init=1; + } diff -B -u -r org/openssl-0.9.7i/crypto/rsa/rsa.h modified/openssl-0.9.7i/crypto/rsa/rsa.h --- org/openssl-0.9.7i/crypto/rsa/rsa.h 2005-06-02 23:37:16.000000000 +0530 +++ modified/openssl-0.9.7i/crypto/rsa/rsa.h 2006-03-28 17:32:48.000000000 +0530 @@ -326,6 +326,7 @@ * made after this point may be overwritten when the script is next run. */ void ERR_load_RSA_strings(void); +void ERR_unload_RSA_strings(void); /* Error codes for the RSA functions. */ diff -B -u -r org/openssl-0.9.7i/crypto/ui/ui_err.c modified/openssl-0.9.7i/crypto/ui/ui_err.c --- org/openssl-0.9.7i/crypto/ui/ui_err.c 2005-04-12 19:17:56.000000000 +0530 +++ modified/openssl-0.9.7i/crypto/ui/ui_err.c 2006-03-28 17:34:01.000000000 +0530 @@ -99,13 +99,12 @@ #endif +static int ERR_UI_init=1; void ERR_load_UI_strings(void) { - static int init=1; - - if (init) + if (ERR_UI_init) { - init=0; + ERR_UI_init=0; #ifndef OPENSSL_NO_ERR ERR_load_strings(0,UI_str_functs); ERR_load_strings(0,UI_str_reasons); @@ -113,3 +112,7 @@ } } +void ERR_unload_UI_strings(void) + { + ERR_UI_init=1; + } diff -B -u -r org/openssl-0.9.7i/crypto/ui/ui.h modified/openssl-0.9.7i/crypto/ui/ui.h --- org/openssl-0.9.7i/crypto/ui/ui.h 2002-02-05 22:45:17.000000000 +0530 +++ modified/openssl-0.9.7i/crypto/ui/ui.h 2006-03-28 17:34:21.000000000 +0530 @@ -355,6 +355,7 @@ * made after this point may be overwritten when the script is next run. */ void ERR_load_UI_strings(void); +void ERR_unload_UI_strings(void); /* Error codes for the UI functions. */ diff -B -u -r org/openssl-0.9.7i/crypto/x509/x509_err.c modified/openssl-0.9.7i/crypto/x509/x509_err.c --- org/openssl-0.9.7i/crypto/x509/x509_err.c 2005-04-12 19:17:57.000000000 +0530 +++ modified/openssl-0.9.7i/crypto/x509/x509_err.c 2006-03-28 17:35:12.000000000 +0530 @@ -144,13 +144,12 @@ #endif +static int ERR_X509_init=1; void ERR_load_X509_strings(void) { - static int init=1; - - if (init) + if (ERR_X509_init) { - init=0; + ERR_X509_init=0; #ifndef OPENSSL_NO_ERR ERR_load_strings(0,X509_str_functs); ERR_load_strings(0,X509_str_reasons); @@ -158,3 +157,7 @@ } } +void ERR_unload_X509_strings(void) + { + ERR_X509_init=1; + } diff -B -u -r org/openssl-0.9.7i/crypto/x509/x509.h modified/openssl-0.9.7i/crypto/x509/x509.h --- org/openssl-0.9.7i/crypto/x509/x509.h 2005-03-23 13:51:29.000000000 +0530 +++ modified/openssl-0.9.7i/crypto/x509/x509.h 2006-03-28 17:35:33.000000000 +0530 @@ -1182,6 +1182,7 @@ * made after this point may be overwritten when the script is next run. */ void ERR_load_X509_strings(void); +void ERR_unload_X509_strings(void); /* Error codes for the X509 functions. */ diff -B -u -r org/openssl-0.9.7i/crypto/x509v3/v3err.c modified/openssl-0.9.7i/crypto/x509v3/v3err.c --- org/openssl-0.9.7i/crypto/x509v3/v3err.c 2005-04-12 19:17:57.000000000 +0530 +++ modified/openssl-0.9.7i/crypto/x509v3/v3err.c 2006-03-28 17:36:24.000000000 +0530 @@ -181,13 +181,12 @@ #endif +static int ERR_X509V3_init=1; void ERR_load_X509V3_strings(void) { - static int init=1; - - if (init) + if (ERR_X509V3_init) { - init=0; + ERR_X509V3_init=0; #ifndef OPENSSL_NO_ERR ERR_load_strings(0,X509V3_str_functs); ERR_load_strings(0,X509V3_str_reasons); @@ -195,3 +194,7 @@ } } +void ERR_unload_X509V3_strings(void) + { + ERR_X509V3_init=1; + } diff -B -u -r org/openssl-0.9.7i/crypto/x509v3/x509v3.h modified/openssl-0.9.7i/crypto/x509v3/x509v3.h --- org/openssl-0.9.7i/crypto/x509v3/x509v3.h 2005-04-11 20:33:30.000000000 +0530 +++ modified/openssl-0.9.7i/crypto/x509v3/x509v3.h 2006-03-28 17:36:54.000000000 +0530 @@ -573,6 +573,7 @@ * made after this point may be overwritten when the script is next run. */ void ERR_load_X509V3_strings(void); +void ERR_unload_X509V3_strings(void); /* Error codes for the X509V3 functions. */ diff -B -u -r org/openssl-0.9.7i/fips/fips_err.h modified/openssl-0.9.7i/fips/fips_err.h --- org/openssl-0.9.7i/fips/fips_err.h 2006-03-29 16:45:39.000000000 +0530 +++ modified/openssl-0.9.7i/fips/fips_err.h 2006-03-29 16:44:19.000000000 +0530 @@ -112,12 +112,12 @@ #endif +static int ERR_FIPS_init=1; void ERR_load_FIPS_strings(void) { - static int init=1; - if (init) + if (ERR_FIPS_init) { - init=0; + ERR_FIPS_init=0; #ifndef OPENSSL_NO_ERR ERR_load_strings(0,FIPS_str_functs); ERR_load_strings(0,FIPS_str_reasons); @@ -125,3 +125,7 @@ } } +void ERR_unload_FIPS_strings(void) + { + ERR_FIPS_init=1; + } diff -B -u -r org/openssl-0.9.7i/fips/fips.h modified/openssl-0.9.7i/fips/fips.h --- org/openssl-0.9.7i/fips/fips.h 2006-03-29 16:45:05.000000000 +0530 +++ modified/openssl-0.9.7i/fips/fips.h 2006-03-29 16:44:11.000000000 +0530 @@ -81,12 +81,14 @@ * made after this point may be overwritten when the script is next run. */ void ERR_load_FIPS_strings(void); +void ERR_unload_FIPS_strings(void); /* BEGIN ERROR CODES */ /* The following lines are auto generated by the script mkerr.pl. Any changes * made after this point may be overwritten when the script is next run. */ void ERR_load_FIPS_strings(void); +void ERR_unload_FIPS_strings(void); /* Error codes for the FIPS functions. */ diff -B -u -r org/openssl-0.9.7i/ssl/ssl_err.c modified/openssl-0.9.7i/ssl/ssl_err.c --- org/openssl-0.9.7i/ssl/ssl_err.c 2005-06-11 01:30:39.000000000 +0530 +++ modified/openssl-0.9.7i/ssl/ssl_err.c 2006-03-28 17:37:40.000000000 +0530 @@ -453,13 +453,12 @@ #endif +static int ERR_SSL_init=1; void ERR_load_SSL_strings(void) { - static int init=1; - - if (init) + if (ERR_SSL_init) { - init=0; + ERR_SSL_init=0; #ifndef OPENSSL_NO_ERR ERR_load_strings(0,SSL_str_functs); ERR_load_strings(0,SSL_str_reasons); @@ -467,3 +466,7 @@ } } +void ERR_unload_SSL_strings(void) + { + ERR_SSL_init=1; + } diff -B -u -r org/openssl-0.9.7i/ssl/ssl.h modified/openssl-0.9.7i/ssl/ssl.h --- org/openssl-0.9.7i/ssl/ssl.h 2005-10-11 15:40:05.000000000 +0530 +++ modified/openssl-0.9.7i/ssl/ssl.h 2006-03-28 17:38:03.000000000 +0530 @@ -1474,6 +1474,7 @@ * made after this point may be overwritten when the script is next run. */ void ERR_load_SSL_strings(void); +void ERR_unload_SSL_strings(void); /* Error codes for the SSL functions. */