Skip to content

Commit 8c9d176

Browse files
author
tb
committed
bio chain test: make two errors noisy
1 parent ab735ec commit 8c9d176

File tree

1 file changed

+11
-3
lines changed

1 file changed

+11
-3
lines changed

src/regress/lib/libcrypto/bio/bio_chain.c

Lines changed: 11 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
/* $OpenBSD: bio_chain.c,v 1.9 2022/12/09 07:47:59 tb Exp $ */
1+
/* $OpenBSD: bio_chain.c,v 1.10 2022/12/09 07:53:06 tb Exp $ */
22
/*
33
* Copyright (c) 2022 Theo Buehler <tb@openbsd.org>
44
*
@@ -201,8 +201,12 @@ walk_forward(BIO *start, BIO *end, size_t expected_len, size_t i, size_t j,
201201
int ret = 0;
202202

203203
if (start == NULL || end == NULL) {
204-
if (expected_len != 0)
204+
if (expected_len != 0) {
205+
fprintf(stderr, "%s case (%zu, %zu) %s: empty chain "
206+
"with expected length %zu > 0\n",
207+
fn, i, j, description, expected_len);
205208
goto err;
209+
}
206210
goto done;
207211
}
208212

@@ -244,8 +248,12 @@ walk_backward(BIO *start, BIO *end, size_t expected_len, size_t i, size_t j,
244248
int ret = 0;
245249

246250
if (start == NULL || end == NULL) {
247-
if (expected_len != 0)
251+
if (expected_len != 0) {
252+
fprintf(stderr, "%s case (%zu, %zu) %s: empty chain "
253+
"with expected length %zu > 0\n",
254+
fn, i, j, description, expected_len);
248255
goto err;
256+
}
249257
goto done;
250258
}
251259

0 commit comments

Comments
 (0)