***************************************************
issue:
extra warnings in compilation of ca.c and gost_pmeth

solution:
convert the type to unsigned int before "uppering"

patches:
--- openssl-1.0.1-beta1/apps/ca.c       2011-10-10 01:13:45.000000000 +0200
+++ openssl-1.0.1-beta1.patch/apps/ca.c 2012-01-06 09:03:27.138226800 +0100
@@ -2561,5 +2561,5 @@
        /* Make it Upper Case */
        for (i=0; row[DB_serial][i] != '\0'; i++)
-               row[DB_serial][i] = toupper(row[DB_serial][i]);
+               row[DB_serial][i] = toupper((unsigned char) row[DB_serial][i]);



--- openssl-1.0.1-beta1/engines/ccgost/gost_pmeth.c     2009-06-16
18:39:20.000000000 +0200
+++ openssl-1.0.1-beta1.patch/engines/ccgost/gost_pmeth.c       2012-01-06
09:03:27.419485800 +0100
@@ -124,5 +124,5 @@
                if (strlen(value) == 1)
                        {
-                       switch(toupper(value[0]))
+                       switch(toupper((unsigned char) value[0]))
                                {
                                case 'A':
@@ -143,7 +143,7 @@
                                }
                        }
-               else if ((strlen(value) == 2) && (toupper(value[0]) == 'X'))
+               else if ((strlen(value) == 2) && (toupper((unsigned char) 
value[0]) ==
'X'))
                        {
-                       switch (toupper(value[1]))
+                       switch (toupper((unsigned char) value[1]))
                                {
                                case 'A':
@@ -199,5 +199,5 @@
                if (strlen(value) == 1)
                        {
-                       switch(toupper(value[0]))
+                       switch(toupper((unsigned char) value[0]))
                                {
                                case 'A':
@@ -218,7 +218,7 @@
                                }
                        }
-               else if ((strlen(value) == 2) && (toupper(value[0]) == 'X'))
+               else if ((strlen(value) == 2) && (toupper((unsigned char) 
value[0]) ==
'X'))
                        {
-                       switch (toupper(value[1]))
+                       switch (toupper((unsigned char) value[1]))
                                {
                                case 'A':



______________________________________________________________________
OpenSSL Project                                 http://www.openssl.org
Development Mailing List                       [email protected]
Automated List Manager                           [email protected]

Reply via email to