| Date: Sun, 7 Jun 2020 21:19:50 +0200
read: fix check for EINTR
Signed-off-by: Christoph Lohmann <20h@r-36.net>
Diffstat:
main.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
--- |
| t@@ -797,7 +797,7 @@ main(int argc, char *argv[])
close(tlspipe[1]);
do {
shuflen = read(tlspipe[0], shufbuf, sizeof(shufbuf)-1);
- if (shuflen == EINTR)
+ if (shuflen == -1 && errno == EINTR)
continue;
for (shufpos = 0; shufpos < shuflen; shufpos += wlen) {
wlen = tls_write(tlsclientctx, shufbuf+shufpos, shuflen-shufpos); |