From: ueno Date: Fri, 11 Aug 2006 02:52:39 +0000 (+0000) Subject: Removed unused local variables. X-Git-Url: http://git.chise.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=a6aa8be630ab2e06572188745def44d1be0a6775;p=elisp%2Fstarttls.git Removed unused local variables. --- diff --git a/starttls.c b/starttls.c index 259960a..4159c5f 100644 --- a/starttls.c +++ b/starttls.c @@ -167,10 +167,10 @@ main (argc, argv) { int in = fileno (stdin), out = fileno (stdout), nbuffer, wrote; - struct pollfd readfds[2], writefds[1]; - char buffer[BUFSIZ], *retry; + struct pollfd readfds[2]; + char buffer[BUFSIZ]; struct sigaction act; - sigset_t orig_mask; + sigset_t mask, orig_mask; int this_option_optind = optind ? optind : 1; int option_index = 0, c; @@ -225,21 +225,22 @@ main (argc, argv) memset (&act, 0, sizeof (act)); act.sa_handler = do_tls_negotiate; sigemptyset (&act.sa_mask); - sigaddset (&act.sa_mask, SIGALRM); act.sa_flags = SA_RESTART|SA_RESETHAND; sigaction (SIGALRM, &act, NULL); + sigemptyset (&mask); + sigaddset (&mask, SIGALRM); + readfds[0].fd = in; readfds[1].fd = tls_fd; readfds[0].events = POLLIN; readfds[1].events = POLLIN; - writefds[0].events = POLLOUT; while (1) { int ready; - sigprocmask (SIG_SETMASK, &act.sa_mask, &orig_mask); + sigprocmask (SIG_SETMASK, &mask, &orig_mask); ready = poll (readfds, 2, -1); sigprocmask (SIG_SETMASK, &orig_mask, NULL); if (ready == -1 && errno != EINTR)