check return value

git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@23664 ec53bebd-3082-4978-b11e-865c3cabbd6b
This commit is contained in:
Love Hörnquist Åstrand
2008-08-25 02:31:04 +00:00
parent ab3d0e36c0
commit cf6451436b

View File

@@ -1515,10 +1515,13 @@ hx509_crl_sign(hx509_context context,
&c.signatureAlgorithm,
&c.signatureValue);
free(os->data);
if (ret) {
hx509_set_error_string(context, 0, ret, "Failed to sign CRL");
goto out;
}
ASN1_MALLOC_ENCODE(CRLCertificateList, os->data, os->length,
&c, &size, ret);
free_CRLCertificateList(&c);
if (ret) {
hx509_set_error_string(context, 0, ret, "failed to encode CRL");
goto out;
@@ -1526,6 +1529,8 @@ hx509_crl_sign(hx509_context context,
if (size != os->length)
_hx509_abort("internal ASN.1 encoder error");
free_CRLCertificateList(&c);
return 0;
out: