(parse_certificate): return errno's not 1 in case of error
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@15745 ec53bebd-3082-4978-b11e-865c3cabbd6b
This commit is contained in:
@@ -90,20 +90,16 @@ parse_certificate(const char *fn, int use_pem, Certificate *t)
|
|||||||
fclose(f);
|
fclose(f);
|
||||||
|
|
||||||
if (data == NULL)
|
if (data == NULL)
|
||||||
return 1;
|
return ENOENT;
|
||||||
|
|
||||||
if (data && in_cert) {
|
if (data && in_cert) {
|
||||||
free(data);
|
free(data);
|
||||||
return 1;
|
return EINVAL;
|
||||||
}
|
}
|
||||||
|
|
||||||
ret = decode_Certificate(data, len, t, &size);
|
ret = decode_Certificate(data, len, t, &size);
|
||||||
free(data);
|
free(data);
|
||||||
if (ret != 0) {
|
return ret;
|
||||||
return 1;
|
|
||||||
}
|
|
||||||
|
|
||||||
return 0;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user