if (readfds[0].revents & POLLIN)
{
nbuffer = read (in, buffer, sizeof buffer -1);
-
if (nbuffer == 0)
goto finish;
redirect (tls_fd, buffer, nbuffer, tls_write);
}
if (readfds[1].revents & POLLIN)
- {
-readtop:
- nbuffer = tls_read(tls_fd, buffer, sizeof buffer -1);
+ do {
+ nbuffer = tls_read (tls_fd, buffer, sizeof buffer -1);
if (nbuffer == 0)
goto finish;
redirect (out, buffer, nbuffer, write);
- if (tls_pending())
- goto readtop;
- }
+ } while (tls_pending ());
}
finish: