A general spring-cleaning (in autumn) to fix up signed/unsigned warnings.
[openssl.git] / crypto / x509 / x509_trs.c
index 881252608d1ff69ed97da031c2ed8bb250a386f9..9c84a59d523c639dbf59f7353eabc614d4928d60 100644 (file)
@@ -128,7 +128,7 @@ int X509_TRUST_get_count(void)
 X509_TRUST * X509_TRUST_get0(int idx)
 {
        if(idx < 0) return NULL;
-       if(idx < X509_TRUST_COUNT) return trstandard + idx;
+       if(idx < (int)X509_TRUST_COUNT) return trstandard + idx;
        return sk_X509_TRUST_value(trtable, idx - X509_TRUST_COUNT);
 }
 
@@ -219,7 +219,7 @@ static void trtable_free(X509_TRUST *p)
 
 void X509_TRUST_cleanup(void)
 {
-       int i;
+       unsigned int i;
        for(i = 0; i < X509_TRUST_COUNT; i++) trtable_free(trstandard + i);
        sk_X509_TRUST_pop_free(trtable, trtable_free);
        trtable = NULL;