mirror of
				https://github.com/tmux/tmux.git
				synced 2025-11-04 00:56:10 +00:00 
			
		
		
		
	Nits found with clang.
This commit is contained in:
		@@ -72,7 +72,6 @@ cmd_command_prompt_exec(struct cmd *self, struct cmdq_item *item)
 | 
				
			|||||||
	struct client			*c = item->state.c;
 | 
						struct client			*c = item->state.c;
 | 
				
			||||||
	char				*prompt, *ptr, *input = NULL;
 | 
						char				*prompt, *ptr, *input = NULL;
 | 
				
			||||||
	size_t				 n;
 | 
						size_t				 n;
 | 
				
			||||||
	int				 flags;
 | 
					 | 
				
			||||||
 | 
					
 | 
				
			||||||
	if (c->prompt_string != NULL)
 | 
						if (c->prompt_string != NULL)
 | 
				
			||||||
		return (CMD_RETURN_NORMAL);
 | 
							return (CMD_RETURN_NORMAL);
 | 
				
			||||||
@@ -117,7 +116,6 @@ cmd_command_prompt_exec(struct cmd *self, struct cmdq_item *item)
 | 
				
			|||||||
		input = strsep(&cdata->next_input, ",");
 | 
							input = strsep(&cdata->next_input, ",");
 | 
				
			||||||
	}
 | 
						}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	flags = 0;
 | 
					 | 
				
			||||||
	if (args_has(args, '1'))
 | 
						if (args_has(args, '1'))
 | 
				
			||||||
		cdata->flags |= PROMPT_SINGLE;
 | 
							cdata->flags |= PROMPT_SINGLE;
 | 
				
			||||||
	else if (args_has(args, 'N'))
 | 
						else if (args_has(args, 'N'))
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -89,7 +89,7 @@ cmd_load_buffer_exec(struct cmd *self, struct cmdq_item *item)
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
	if (c != NULL && c->session == NULL && c->cwd != NULL)
 | 
						if (c != NULL && c->session == NULL && c->cwd != NULL)
 | 
				
			||||||
		cwd = c->cwd;
 | 
							cwd = c->cwd;
 | 
				
			||||||
	else if ((s = c->session) != NULL && s->cwd != NULL)
 | 
						else if (c != NULL && (s = c->session) != NULL && s->cwd != NULL)
 | 
				
			||||||
		cwd = s->cwd;
 | 
							cwd = s->cwd;
 | 
				
			||||||
	else
 | 
						else
 | 
				
			||||||
		cwd = ".";
 | 
							cwd = ".";
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -100,7 +100,7 @@ cmd_save_buffer_exec(struct cmd *self, struct cmdq_item *item)
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
	if (c != NULL && c->session == NULL && c->cwd != NULL)
 | 
						if (c != NULL && c->session == NULL && c->cwd != NULL)
 | 
				
			||||||
		cwd = c->cwd;
 | 
							cwd = c->cwd;
 | 
				
			||||||
	else if ((s = c->session) != NULL && s->cwd != NULL)
 | 
						else if (c != NULL && (s = c->session) != NULL && s->cwd != NULL)
 | 
				
			||||||
		cwd = s->cwd;
 | 
							cwd = s->cwd;
 | 
				
			||||||
	else
 | 
						else
 | 
				
			||||||
		cwd = ".";
 | 
							cwd = ".";
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -102,7 +102,7 @@ cmd_switch_client_exec(struct cmd *self, struct cmdq_item *item)
 | 
				
			|||||||
		}
 | 
							}
 | 
				
			||||||
	}
 | 
						}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	if (c != NULL && !args_has(args, 'E')) {
 | 
						if (!args_has(args, 'E')) {
 | 
				
			||||||
		update = options_get_string(s->options, "update-environment");
 | 
							update = options_get_string(s->options, "update-environment");
 | 
				
			||||||
		environ_update(update, c->environ, s->environ);
 | 
							environ_update(update, c->environ, s->environ);
 | 
				
			||||||
	}
 | 
						}
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user