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

Diff for /src/usr.bin/tmux/session.c between version 1.69 and 1.70

version 1.69, 2016/10/19 08:17:11 version 1.70, 2016/10/19 09:22:07
Line 337 
Line 337 
                 xasprintf(cause, "index in use: %d", idx);                  xasprintf(cause, "index in use: %d", idx);
                 return (NULL);                  return (NULL);
         }          }
           wl->session = s;
   
         env = environ_create();          env = environ_create();
         environ_copy(global_environ, env);          environ_copy(global_environ, env);
Line 373 
Line 374 
                 xasprintf(cause, "index in use: %d", idx);                  xasprintf(cause, "index in use: %d", idx);
                 return (NULL);                  return (NULL);
         }          }
           wl->session = s;
         winlink_set_window(wl, w);          winlink_set_window(wl, w);
         notify_session_window("window-linked", s, w);          notify_session_window("window-linked", s, w);
   
Line 409 
Line 411 
 {  {
         struct winlink  *wl;          struct winlink  *wl;
   
         RB_FOREACH(wl, winlinks, &s->windows) {          TAILQ_FOREACH(wl, &w->winlinks, wentry) {
                 if (wl->window == w)                  if (wl->session == s)
                         return (1);                          return (1);
         }          }
         return (0);          return (0);
Line 679 
Line 681 
         /* Link all the windows from the target. */          /* Link all the windows from the target. */
         RB_FOREACH(wl, winlinks, ww) {          RB_FOREACH(wl, winlinks, ww) {
                 wl2 = winlink_add(&s->windows, wl->idx);                  wl2 = winlink_add(&s->windows, wl->idx);
                   wl2->session = s;
                 winlink_set_window(wl2, wl->window);                  winlink_set_window(wl2, wl->window);
                 notify_session_window("window-linked", s, wl2->window);                  notify_session_window("window-linked", s, wl2->window);
                 wl2->flags |= wl->flags & WINLINK_ALERTFLAGS;                  wl2->flags |= wl->flags & WINLINK_ALERTFLAGS;
Line 729 
Line 732 
         /* Go through the winlinks and assign new indexes. */          /* Go through the winlinks and assign new indexes. */
         RB_FOREACH(wl, winlinks, &old_wins) {          RB_FOREACH(wl, winlinks, &old_wins) {
                 wl_new = winlink_add(&s->windows, new_idx);                  wl_new = winlink_add(&s->windows, new_idx);
                   wl_new->session = s;
                 winlink_set_window(wl_new, wl->window);                  winlink_set_window(wl_new, wl->window);
                 wl_new->flags |= wl->flags & WINLINK_ALERTFLAGS;                  wl_new->flags |= wl->flags & WINLINK_ALERTFLAGS;
   

Legend:
Removed from v.1.69  
changed lines
  Added in v.1.70