summaryrefslogtreecommitdiff
path: root/src/lib/tls/x509_nss.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/lib/tls/x509_nss.c')
-rw-r--r--src/lib/tls/x509_nss.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/lib/tls/x509_nss.c b/src/lib/tls/x509_nss.c
index 35b3d2542b..68aebbb69a 100644
--- a/src/lib/tls/x509_nss.c
+++ b/src/lib/tls/x509_nss.c
@@ -62,9 +62,11 @@ tor_tls_create_certificate_internal(crypto_pk_t *rsa,
validity = CERT_CreateValidity(((PRTime)start_time) * PRTIME_PER_SEC,
((PRTime)end_time) * PRTIME_PER_SEC);
- if (! validity) {
+ if (BUG(! validity)) {
+ /* LCOV_EXCL_START */
crypto_nss_log_errors(LOG_WARN, "creating a validity object");
goto err;
+ /* LCOV_EXCL_STOP */
}
unsigned long serial_number;