From: ueno Date: Fri, 11 Aug 2006 02:46:02 +0000 (+0000) Subject: Don't use goto readtop: X-Git-Url: http://git.chise.org/gitweb/?a=commitdiff_plain;h=7fac4634eafd2959dc216b6d389818fe85c133d2;p=elisp%2Fstarttls.git Don't use goto readtop: --- diff --git a/starttls.c b/starttls.c index 52a2329..259960a 100644 --- a/starttls.c +++ b/starttls.c @@ -251,21 +251,17 @@ main (argc, argv) 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: