Avoid signed vs. unsigned warnings (which are treated like errors on
authorRichard Levitte <levitte@openssl.org>
Tue, 27 Jan 2004 01:16:38 +0000 (01:16 +0000)
committerRichard Levitte <levitte@openssl.org>
Tue, 27 Jan 2004 01:16:38 +0000 (01:16 +0000)
Windows).

crypto/asn1/a_gentm.c
crypto/asn1/a_utctm.c

index 1aba86d..8581007 100644 (file)
@@ -220,7 +220,7 @@ ASN1_GENERALIZEDTIME *ASN1_GENERALIZEDTIME_set(ASN1_GENERALIZEDTIME *s,
                return(NULL);
 
        p=(char *)s->data;
-       if ((p == NULL) || (s->length < len))
+       if ((p == NULL) || ((size_t)s->length < len))
                {
                p=OPENSSL_malloc(len);
                if (p == NULL) return(NULL);
index 6bc609a..999852d 100644 (file)
@@ -200,7 +200,7 @@ ASN1_UTCTIME *ASN1_UTCTIME_set(ASN1_UTCTIME *s, time_t t)
                return(NULL);
 
        p=(char *)s->data;
-       if ((p == NULL) || (s->length < len))
+       if ((p == NULL) || ((size_t)s->length < len))
                {
                p=OPENSSL_malloc(len);
                if (p == NULL) return(NULL);