3874266+4862555-DATAPIG.patch   [plain text]


diff -Nur openssl-0.9.8za/src/crypto/err/err_str.c ./crypto/err/err_str.c
--- openssl-0.9.8za/src/crypto/err/err_str.c	2014-06-05 01:09:08.000000000 -0700
+++ ./crypto/err/err_str.c	2014-07-09 17:55:16.000000000 -0700
@@ -120,7 +120,12 @@
 #include <openssl/err.h>
 
 #ifndef OPENSSL_NO_ERR
-static ERR_STRING_DATA ERR_str_libraries[]=
+#if __APPLE__
+#define CONST_DATA const // we want to mark these items const on OSX
+#else
+#define CONST_DATA       // but not on Windows
+#endif
+CONST_DATA static ERR_STRING_DATA ERR_str_libraries[]=
 	{
 {ERR_PACK(ERR_LIB_NONE,0,0)		,"unknown library"},
 {ERR_PACK(ERR_LIB_SYS,0,0)		,"system library"},
@@ -152,7 +157,7 @@
 {0,NULL},
 	};
 
-static ERR_STRING_DATA ERR_str_functs[]=
+CONST_DATA static ERR_STRING_DATA ERR_str_functs[]=
 	{
 	{ERR_PACK(0,SYS_F_FOPEN,0),     	"fopen"},
 	{ERR_PACK(0,SYS_F_CONNECT,0),		"connect"},
@@ -170,7 +175,7 @@
 	{0,NULL},
 	};
 
-static ERR_STRING_DATA ERR_str_reasons[]=
+CONST_DATA static ERR_STRING_DATA ERR_str_reasons[]=
 	{
 {ERR_R_SYS_LIB				,"system lib"},
 {ERR_R_BN_LIB				,"BN lib"},
diff -Nur openssl-0.9.8za/src/crypto/objects/obj_dat.h ./crypto/objects/obj_dat.h
--- openssl-0.9.8za/src/crypto/objects/obj_dat.h	2014-06-05 02:38:45.000000000 -0700
+++ ./crypto/objects/obj_dat.h	2014-07-09 17:55:16.000000000 -0700
@@ -910,7 +910,7 @@
 0x55,0x04,0x36,                              /* [5820] OBJ_dmdName */
 };
 
-static ASN1_OBJECT nid_objs[NUM_NID]={
+const static ASN1_OBJECT nid_objs[NUM_NID]={
 {"UNDEF","undefined",NID_undef,1,&(lvalues[0]),0},
 {"rsadsi","RSA Data Security, Inc.",NID_rsadsi,6,&(lvalues[1]),0},
 {"pkcs","RSA Data Security, Inc. PKCS",NID_pkcs,7,&(lvalues[7]),0},
@@ -2353,7 +2353,7 @@
 {"dmdName","dmdName",NID_dmdName,3,&(lvalues[5820]),0},
 };
 
-static ASN1_OBJECT *sn_objs[NUM_SN]={
+const static ASN1_OBJECT *const sn_objs[NUM_SN]={
 &(nid_objs[364]),/* "AD_DVCS" */
 &(nid_objs[419]),/* "AES-128-CBC" */
 &(nid_objs[421]),/* "AES-128-CFB" */
@@ -3242,7 +3242,7 @@
 &(nid_objs[160]),/* "x509Crl" */
 };
 
-static ASN1_OBJECT *ln_objs[NUM_LN]={
+const static ASN1_OBJECT *const ln_objs[NUM_LN]={
 &(nid_objs[363]),/* "AD Time Stamping" */
 &(nid_objs[405]),/* "ANSI X9.62" */
 &(nid_objs[368]),/* "Acceptable OCSP Responses" */
@@ -4131,7 +4131,7 @@
 &(nid_objs[125]),/* "zlib compression" */
 };
 
-static ASN1_OBJECT *obj_objs[NUM_OBJ]={
+const static ASN1_OBJECT *const obj_objs[NUM_OBJ]={
 &(nid_objs[ 0]),/* OBJ_undef                        0 */
 &(nid_objs[393]),/* OBJ_joint_iso_ccitt              OBJ_joint_iso_itu_t */
 &(nid_objs[404]),/* OBJ_ccitt                        OBJ_itu_t */