projects
/
oweals
/
openssl.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
openssl dgst, openssl enc: check for end of input
[oweals/openssl.git]
/
apps
/
dgst.c
diff --git
a/apps/dgst.c
b/apps/dgst.c
index 7b433385861625595529080fe40c4dec7c1219d3..b44468bc796a61287530e9f28481a09b495413c6 100644
(file)
--- a/
apps/dgst.c
+++ b/
apps/dgst.c
@@
-461,7
+461,7
@@
int do_fp(BIO *out, unsigned char *buf, BIO *bp, int sep, int binout,
size_t len;
int i, backslash = 0;
-
for (;;
) {
+
while (BIO_pending(bp) || !BIO_eof(bp)
) {
i = BIO_read(bp, (char *)buf, BUFSIZE);
if (i < 0) {
BIO_printf(bio_err, "Read Error in %s\n", file);