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

Diff for /src/usr.bin/tmux/spawn.c between version 1.6 and 1.7

version 1.6, 2019/06/30 19:21:53 version 1.7, 2019/09/18 11:37:58
Line 332 
Line 332 
         cmd_log_argv(new_wp->argc, new_wp->argv, "%s", __func__);          cmd_log_argv(new_wp->argc, new_wp->argv, "%s", __func__);
         environ_log(child, "%s: environment ", __func__);          environ_log(child, "%s: environment ", __func__);
   
         /* If the command is empty, don't fork a child process. */  
         if (sc->flags & SPAWN_EMPTY) {  
                 new_wp->flags |= PANE_EMPTY;  
                 new_wp->base.mode &= ~MODE_CURSOR;  
                 new_wp->base.mode |= MODE_CRLF;  
                 goto complete;  
         }  
   
         /* Initialize the window size. */          /* Initialize the window size. */
         memset(&ws, 0, sizeof ws);          memset(&ws, 0, sizeof ws);
         ws.ws_col = screen_size_x(&new_wp->base);          ws.ws_col = screen_size_x(&new_wp->base);
Line 348 
Line 340 
         /* Block signals until fork has completed. */          /* Block signals until fork has completed. */
         sigfillset(&set);          sigfillset(&set);
         sigprocmask(SIG_BLOCK, &set, &oldset);          sigprocmask(SIG_BLOCK, &set, &oldset);
   
           /* If the command is empty, don't fork a child process. */
           if (sc->flags & SPAWN_EMPTY) {
                   new_wp->flags |= PANE_EMPTY;
                   new_wp->base.mode &= ~MODE_CURSOR;
                   new_wp->base.mode |= MODE_CRLF;
                   goto complete;
           }
   
         /* Fork the new process. */          /* Fork the new process. */
         new_wp->pid = fdforkpty(ptm_fd, &new_wp->fd, new_wp->tty, NULL, &ws);          new_wp->pid = fdforkpty(ptm_fd, &new_wp->fd, new_wp->tty, NULL, &ws);

Legend:
Removed from v.1.6  
changed lines
  Added in v.1.7