summaryrefslogtreecommitdiffstats
path: root/crypto/objects
diff options
context:
space:
mode:
authorBodo Möller <bodo@openssl.org>1999-05-10 11:18:26 +0000
committerBodo Möller <bodo@openssl.org>1999-05-10 11:18:26 +0000
commit84a370a4002740d8311e5c6950071dfff436395b (patch)
tree620d65dcdcda536fd49f0e38fb856de4aeea60d8 /crypto/objects
parent93c5624f04a4a371bdbd66af264743f0bad8c516 (diff)
The various character predicates (isspace and the like) may not be
used with negative char values, so I've added casts to unsigned char. Maybe what really should be done is change all those arrays and pointers to type unsigned char [] or unsigned char *, respectively; but using plain char with those predicates is just wrong, so something had to be done. Submitted by: Reviewed by: PR:
Diffstat (limited to 'crypto/objects')
-rw-r--r--crypto/objects/obj_dat.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/crypto/objects/obj_dat.c b/crypto/objects/obj_dat.c
index cfc082add3..0b24b14446 100644
--- a/crypto/objects/obj_dat.c
+++ b/crypto/objects/obj_dat.c
@@ -512,26 +512,26 @@ int OBJ_create_objects(BIO *in)
i=BIO_gets(in,buf,512);
if (i <= 0) return(num);
buf[i-1]='\0';
- if (!isalnum(buf[0])) return(num);
+ if (!isalnum((unsigned char)buf[0])) return(num);
o=s=buf;
- while (isdigit(*s) || (*s == '.'))
+ while (isdigit((unsigned char)*s) || (*s == '.'))
s++;
if (*s != '\0')
{
*(s++)='\0';
- while (isspace(*s))
+ while (isspace((unsigned char)*s))
s++;
if (*s == '\0')
s=NULL;
else
{
l=s;
- while ((*l != '\0') && !isspace(*l))
+ while ((*l != '\0') && !isspace((unsigned char)*l))
l++;
if (*l != '\0')
{
*(l++)='\0';
- while (isspace(*l))
+ while (isspace((unsigned char)*l))
l++;
if (*l == '\0') l=NULL;
}