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

Diff for /src/usr.bin/tmux/cmd-find.c between version 1.20 and 1.21

version 1.20, 2015/12/13 16:44:35 version 1.21, 2015/12/13 17:55:14
Line 467 
Line 467 
   
         /* Otherwise try as a session itself. */          /* Otherwise try as a session itself. */
         if (cmd_find_get_session(fs, window) == 0) {          if (cmd_find_get_session(fs, window) == 0) {
                 if (~fs->flags & CMD_FIND_WINDOW_INDEX) {                  fs->wl = fs->s->curw;
                         fs->wl = fs->s->curw;                  fs->w = fs->wl->window;
                         fs->w = fs->wl->window;                  if (~fs->flags & CMD_FIND_WINDOW_INDEX)
                         fs->idx = fs->wl->idx;                          fs->idx = fs->wl->idx;
                 }  
                 return (0);                  return (0);
         }          }
   
Line 493 
Line 492 
         log_debug("%s: %s", __func__, window);          log_debug("%s: %s", __func__, window);
         exact = (fs->flags & CMD_FIND_EXACT_WINDOW);          exact = (fs->flags & CMD_FIND_EXACT_WINDOW);
   
           /*
            * Start with the current window as the default. So if only an index is
            * found, the window will be the current.
            */
           fs->wl = fs->s->curw;
           fs->w = fs->wl->window;
   
         /* Check for window ids starting with @. */          /* Check for window ids starting with @. */
         if (*window == '@') {          if (*window == '@') {
                 fs->w = window_find_by_id_str(window);                  fs->w = window_find_by_id_str(window);
Line 976 
Line 982 
                         /* This will fill in winlink and window. */                          /* This will fill in winlink and window. */
                         if (cmd_find_get_window_with_session(fs, window) != 0)                          if (cmd_find_get_window_with_session(fs, window) != 0)
                                 goto no_window;                                  goto no_window;
                         if (~flags & CMD_FIND_WINDOW_INDEX)                          fs->wp = fs->wl->window->active;
                                 fs->wp = fs->wl->window->active;  
                         goto found;                          goto found;
                 }                  }
   
Line 1017 
Line 1022 
                 /* This will fill in session, winlink and window. */                  /* This will fill in session, winlink and window. */
                 if (cmd_find_get_window(fs, window) != 0)                  if (cmd_find_get_window(fs, window) != 0)
                         goto no_window;                          goto no_window;
                 if (~flags & CMD_FIND_WINDOW_INDEX)                  fs->wp = fs->wl->window->active;
                         fs->wp = fs->wl->window->active;  
                 goto found;                  goto found;
         }          }
   

Legend:
Removed from v.1.20  
changed lines
  Added in v.1.21