X-Git-Url: https://asedeno.scripts.mit.edu/gitweb/?a=blobdiff_plain;f=unix%2Fuxplink.c;h=bf55ea73e93b875ebf262edcdad1b913869b3c93;hb=095072fa46b2d7b8beafaddb2f873d2f500a1e10;hp=b8c554894002033dcb0e5583fd0285b9223bf11c;hpb=2057f7a9f8ab56bca2aa4d827758dec21a13394c;p=PuTTY.git diff --git a/unix/uxplink.c b/unix/uxplink.c index b8c55489..bf55ea73 100644 --- a/unix/uxplink.c +++ b/unix/uxplink.c @@ -305,6 +305,9 @@ char *get_ttymode(void *frontend, const char *mode) #endif #if defined(XCASE) GET_BOOL("XCASE", XCASE, c_lflag, ); +#endif +#if defined(IUTF8) + GET_BOOL("IUTF8", IUTF8, c_iflag, ); #endif /* Configuration of ECHO */ #if defined(ECHOCTL) @@ -581,6 +584,9 @@ static void usage(void) printf(" -N don't start a shell/command (SSH-2 only)\n"); printf(" -nc host:port\n"); printf(" open tunnel in place of session (SSH-2 only)\n"); + printf(" -sshlog file\n"); + printf(" -sshrawlog file\n"); + printf(" log protocol details to a file\n"); printf(" -shareexists\n"); printf(" test whether a connection-sharing upstream exists\n"); exit(1); @@ -588,7 +594,9 @@ static void usage(void) static void version(void) { - printf("plink: %s\n", ver); + char *buildinfo_text = buildinfo("\n"); + printf("plink: %s\n%s\n", ver, buildinfo_text); + sfree(buildinfo_text); exit(1); } @@ -943,6 +951,11 @@ int main(int argc, char **argv) perror("pipe"); exit(1); } + /* We don't want the signal handler to block if the pipe's full. */ + nonblock(signalpipe[0]); + nonblock(signalpipe[1]); + cloexec(signalpipe[0]); + cloexec(signalpipe[1]); putty_signal(SIGWINCH, sigwinch); /* @@ -958,7 +971,7 @@ int main(int argc, char **argv) uxsel_init(); /* - * Unix Plink doesn't provide any way to add forwardings after the + * Plink doesn't provide any way to add forwardings after the * connection is set up, so if there are none now, we can safely set * the "simple" flag. */ @@ -1111,6 +1124,9 @@ int main(int argc, char **argv) ret = select(maxfd, &rset, &wset, &xset, NULL); } + if (ret < 0 && errno == EINTR) + continue; + if (ret < 0) { perror("select"); exit(1);