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

Diff for /src/usr.bin/tmux/cmd-set-option.c between version 1.74 and 1.75

version 1.74, 2015/04/24 23:17:11 version 1.75, 2015/06/04 14:29:33
Line 266 
Line 266 
 {  {
         struct args     *args = self->args;          struct args     *args = self->args;
   
         if (args_has(args, 'g')) {  
                 cmdq_error(cmdq, "can't unset global option: %s", oe->name);  
                 return (-1);  
         }  
         if (value != NULL) {          if (value != NULL) {
                 cmdq_error(cmdq, "value passed to unset option: %s", oe->name);                  cmdq_error(cmdq, "value passed to unset option: %s", oe->name);
                 return (-1);                  return (-1);
         }          }
   
         options_remove(oo, oe->name);          if (args_has(args, 'g') || oo == &global_options) {
                   switch (oe->type) {
                   case OPTIONS_TABLE_STRING:
                           options_set_string(oo, oe->name, "%s", oe->default_str);
                           break;
                   case OPTIONS_TABLE_STYLE:
                           options_set_style(oo, oe->name, oe->default_str, 0);
                           break;
                   default:
                           options_set_number(oo, oe->name, oe->default_num);
                           break;
                   }
           } else
                   options_remove(oo, oe->name);
         return (0);          return (0);
 }  }
   

Legend:
Removed from v.1.74  
changed lines
  Added in v.1.75