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

Diff for /src/usr.bin/tmux/cfg.c between version 1.24 and 1.25

version 1.24, 2013/03/22 10:41:57 version 1.25, 2013/03/22 15:49:55
Line 80 
Line 80 
         char            *buf, *copy, *line, *cause;          char            *buf, *copy, *line, *cause;
         size_t           len, oldlen;          size_t           len, oldlen;
         struct cmd_list *cmdlist;          struct cmd_list *cmdlist;
         struct cmd_ctx   ctx;          struct cmd_ctx  *ctx;
         enum cmd_retval  retval;          enum cmd_retval  retval;
   
         if ((f = fopen(path, "rb")) == NULL) {          if ((f = fopen(path, "rb")) == NULL) {
Line 90 
Line 90 
   
         cfg_references++;          cfg_references++;
   
           ctx = cmd_get_ctx();
           if (ctxin == NULL) {
                   ctx->msgdata = NULL;
                   ctx->curclient = NULL;
                   ctx->cmdclient = NULL;
           } else {
                   ctx->msgdata = ctxin->msgdata;
                   ctx->curclient = ctxin->curclient;
                   ctx->cmdclient = ctxin->cmdclient;
           }
   
           ctx->error = cfg_error;
           ctx->print = cfg_print;
           ctx->info = cfg_print;
   
         n = 0;          n = 0;
         line = NULL;          line = NULL;
         retval = CMD_RETURN_NORMAL;          retval = CMD_RETURN_NORMAL;
Line 146 
Line 161 
                 if (cmdlist == NULL)                  if (cmdlist == NULL)
                         continue;                          continue;
   
                 if (ctxin == NULL) {  
                         ctx.msgdata = NULL;  
                         ctx.curclient = NULL;  
                         ctx.cmdclient = NULL;  
                 } else {  
                         ctx.msgdata = ctxin->msgdata;  
                         ctx.curclient = ctxin->curclient;  
                         ctx.cmdclient = ctxin->cmdclient;  
                 }  
   
                 ctx.error = cfg_error;  
                 ctx.print = cfg_print;  
                 ctx.info = cfg_print;  
   
                 cfg_cause = NULL;                  cfg_cause = NULL;
                 switch (cmd_list_exec(cmdlist, &ctx)) {                  switch (cmd_list_exec(cmdlist, ctx)) {
                 case CMD_RETURN_YIELD:                  case CMD_RETURN_YIELD:
                         if (retval != CMD_RETURN_ATTACH)                          if (retval != CMD_RETURN_ATTACH)
                                 retval = CMD_RETURN_YIELD;                                  retval = CMD_RETURN_YIELD;
Line 185 
Line 186 
                 free(line);                  free(line);
         }          }
         fclose(f);          fclose(f);
   
           cmd_free_ctx(ctx);
   
         cfg_references--;          cfg_references--;
   

Legend:
Removed from v.1.24  
changed lines
  Added in v.1.25