[BACK]Return to client.c CVS log [TXT][DIR] Up to [local] / src / usr.bin / tmux

Diff for /src/usr.bin/tmux/client.c between version 1.55 and 1.56

version 1.55, 2012/05/25 08:28:10 version 1.56, 2012/06/18 13:16:42
Line 169 
Line 169 
         pid_t                    ppid;          pid_t                    ppid;
         enum msgtype             msg;          enum msgtype             msg;
         char                    *cause;          char                    *cause;
           struct termios           tio, saved_tio;
   
         /* Set up the initial command. */          /* Set up the initial command. */
         cmdflags = 0;          cmdflags = 0;
Line 233 
Line 234 
         setblocking(STDIN_FILENO, 0);          setblocking(STDIN_FILENO, 0);
         event_set(&client_stdin, STDIN_FILENO, EV_READ|EV_PERSIST,          event_set(&client_stdin, STDIN_FILENO, EV_READ|EV_PERSIST,
             client_stdin_callback, NULL);              client_stdin_callback, NULL);
           if (flags & IDENTIFY_TERMIOS) {
                   if (tcgetattr(STDIN_FILENO, &saved_tio) != 0) {
                           fprintf(stderr, "tcgetattr failed: %s\n",
                               strerror(errno));
                           return (1);
                   }
                   cfmakeraw(&tio);
                   tio.c_iflag = ICRNL|IXANY;
                   tio.c_oflag = OPOST|ONLCR;
                   tio.c_lflag = NOKERNINFO;
                   tio.c_cflag = CREAD|CS8|HUPCL;
                   tio.c_cc[VMIN] = 1;
                   tio.c_cc[VTIME] = 0;
                   cfsetispeed(&tio, cfgetispeed(&saved_tio));
                   cfsetospeed(&tio, cfgetospeed(&saved_tio));
                   tcsetattr(STDIN_FILENO, TCSANOW, &tio);
           }
   
         /* Establish signal handlers. */          /* Establish signal handlers. */
         set_signals(client_signal);          set_signals(client_signal);
Line 273 
Line 291 
                 ppid = getppid();                  ppid = getppid();
                 if (client_exittype == MSG_DETACHKILL && ppid > 1)                  if (client_exittype == MSG_DETACHKILL && ppid > 1)
                         kill(ppid, SIGHUP);                          kill(ppid, SIGHUP);
         }          } else if (flags & IDENTIFY_TERMIOS)
                   tcsetattr(STDOUT_FILENO, TCSAFLUSH, &saved_tio);
         setblocking(STDIN_FILENO, 1);          setblocking(STDIN_FILENO, 1);
         return (client_exitval);          return (client_exitval);
 }  }
Line 513 
Line 532 
   
                         shell_exec(shelldata.shell, shellcmd);                          shell_exec(shelldata.shell, shellcmd);
                         /* NOTREACHED */                          /* NOTREACHED */
                   case MSG_DETACH:
                           client_write_server(MSG_EXITING, NULL, 0);
                           break;
                   case MSG_EXITED:
                           imsg_free(&imsg);
                           return (-1);
                 default:                  default:
                         fatalx("unexpected message");                          fatalx("unexpected message");
                 }                  }

Legend:
Removed from v.1.55  
changed lines
  Added in v.1.56