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

Diff for /src/usr.bin/tmux/cmd-if-shell.c between version 1.55 and 1.56

version 1.55, 2017/04/22 10:22:39 version 1.56, 2017/04/25 11:49:35
Line 31 
Line 31 
   
 static enum cmd_retval  cmd_if_shell_exec(struct cmd *, struct cmdq_item *);  static enum cmd_retval  cmd_if_shell_exec(struct cmd *, struct cmdq_item *);
   
 static enum cmd_retval  cmd_if_shell_error(struct cmdq_item *, void *);  
 static void             cmd_if_shell_callback(struct job *);  static void             cmd_if_shell_callback(struct job *);
 static void             cmd_if_shell_free(void *);  static void             cmd_if_shell_free(void *);
   
Line 138 
Line 137 
         return (CMD_RETURN_WAIT);          return (CMD_RETURN_WAIT);
 }  }
   
 static enum cmd_retval  
 cmd_if_shell_error(struct cmdq_item *item, void *data)  
 {  
         char    *error = data;  
   
         cmdq_error(item, "%s", error);  
         free(error);  
   
         return (CMD_RETURN_NORMAL);  
 }  
   
 static void  static void
 cmd_if_shell_callback(struct job *job)  cmd_if_shell_callback(struct job *job)
 {  {
Line 168 
Line 156 
   
         cmdlist = cmd_string_parse(cmd, file, line, &cause);          cmdlist = cmd_string_parse(cmd, file, line, &cause);
         if (cmdlist == NULL) {          if (cmdlist == NULL) {
                 if (cause != NULL)                  if (cause != NULL && cdata->item != NULL)
                         new_item = cmdq_get_callback(cmd_if_shell_error, cause);                          cmdq_error(cdata->item, "%s", cause);
                 else                  free(cause);
                         new_item = NULL;                  new_item = NULL;
         } else {          } else {
                 new_item = cmdq_get_command(cmdlist, NULL, &cdata->mouse, 0);                  new_item = cmdq_get_command(cmdlist, NULL, &cdata->mouse, 0);
                 cmd_list_free(cmdlist);                  cmd_list_free(cmdlist);

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