break;
}
}
- sk_GENERAL_NAME_free (extensions);
+ GENERAL_NAMES_free(extensions);
}
return retval;
}
asn1 = X509_NAME_ENTRY_get_data(x509ne);
if (!asn1)
return FAILURE;
- tmp = ASN1_STRING_to_UTF8(&buf, asn1);
- if (tmp <= 0)
+ if (ASN1_STRING_to_UTF8(&buf, asn1) < 0)
return FAILURE;
strncpynt(out, (char *)buf, size);
ASN1_STRING *val = X509_NAME_ENTRY_get_data (ent);
unsigned char *buf;
buf = (unsigned char *)1; /* bug in OpenSSL 0.9.6b ASN1_STRING_to_UTF8 requires this workaround */
- if (ASN1_STRING_to_UTF8 (&buf, val) > 0)
+ if (ASN1_STRING_to_UTF8 (&buf, val) >= 0)
{
do_setenv_x509(es, xt->name, (char *)buf, depth);
OPENSSL_free (buf);
if (!objbuf)
continue;
buf = (unsigned char *)1; /* bug in OpenSSL 0.9.6b ASN1_STRING_to_UTF8 requires this workaround */
- if (ASN1_STRING_to_UTF8 (&buf, val) <= 0)
+ if (ASN1_STRING_to_UTF8 (&buf, val) < 0)
continue;
name_expand_size = 64 + strlen (objbuf);
name_expand = (char *) malloc (name_expand_size);