mirror of
				https://github.com/tmux/tmux.git
				synced 2025-11-04 09:26:05 +00:00 
			
		
		
		
	Zap unused functions, prompted by deraadt.
This commit is contained in:
		@@ -187,20 +187,6 @@ key_bindings_init(void)
 | 
				
			|||||||
	}
 | 
						}
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
void
 | 
					 | 
				
			||||||
key_bindings_free(void)
 | 
					 | 
				
			||||||
{
 | 
					 | 
				
			||||||
	struct key_binding	*bd;
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
	key_bindings_clean();
 | 
					 | 
				
			||||||
	while (!SPLAY_EMPTY(&key_bindings)) {
 | 
					 | 
				
			||||||
		bd = SPLAY_ROOT(&key_bindings);
 | 
					 | 
				
			||||||
		SPLAY_REMOVE(key_bindings, &key_bindings, bd);
 | 
					 | 
				
			||||||
		cmd_list_free(bd->cmdlist);
 | 
					 | 
				
			||||||
		xfree(bd);
 | 
					 | 
				
			||||||
	}
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
void printflike2
 | 
					void printflike2
 | 
				
			||||||
key_bindings_error(struct cmd_ctx *ctx, const char *fmt, ...)
 | 
					key_bindings_error(struct cmd_ctx *ctx, const char *fmt, ...)
 | 
				
			||||||
{
 | 
					{
 | 
				
			||||||
 
 | 
				
			|||||||
							
								
								
									
										15
									
								
								mode-key.c
									
									
									
									
									
								
							
							
						
						
									
										15
									
								
								mode-key.c
									
									
									
									
									
								
							@@ -370,21 +370,6 @@ mode_key_init_trees(void)
 | 
				
			|||||||
	}
 | 
						}
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
void
 | 
					 | 
				
			||||||
mode_key_free_trees(void)
 | 
					 | 
				
			||||||
{
 | 
					 | 
				
			||||||
	const struct mode_key_table	*mtab;
 | 
					 | 
				
			||||||
	struct mode_key_binding		*mbind;
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
	for (mtab = mode_key_tables; mtab->name != NULL; mtab++) {
 | 
					 | 
				
			||||||
		while (!SPLAY_EMPTY(mtab->tree)) {
 | 
					 | 
				
			||||||
			mbind = SPLAY_ROOT(mtab->tree);
 | 
					 | 
				
			||||||
			SPLAY_REMOVE(mode_key_tree, mtab->tree, mbind);
 | 
					 | 
				
			||||||
			xfree(mbind);
 | 
					 | 
				
			||||||
		}
 | 
					 | 
				
			||||||
	}
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
void
 | 
					void
 | 
				
			||||||
mode_key_init(struct mode_key_data *mdata, struct mode_key_tree *mtree)
 | 
					mode_key_init(struct mode_key_data *mdata, struct mode_key_tree *mtree)
 | 
				
			||||||
{
 | 
					{
 | 
				
			||||||
 
 | 
				
			|||||||
							
								
								
									
										2
									
								
								tmux.h
									
									
									
									
									
								
							
							
						
						
									
										2
									
								
								tmux.h
									
									
									
									
									
								
							@@ -1249,7 +1249,6 @@ const char *mode_key_tostring(struct mode_key_cmdstr *r, enum mode_key_cmd);
 | 
				
			|||||||
enum mode_key_cmd mode_key_fromstring(struct mode_key_cmdstr *, const char *);
 | 
					enum mode_key_cmd mode_key_fromstring(struct mode_key_cmdstr *, const char *);
 | 
				
			||||||
const struct mode_key_table *mode_key_findtable(const char *);
 | 
					const struct mode_key_table *mode_key_findtable(const char *);
 | 
				
			||||||
void	mode_key_init_trees(void);
 | 
					void	mode_key_init_trees(void);
 | 
				
			||||||
void	mode_key_free_trees(void);
 | 
					 | 
				
			||||||
void	mode_key_init(struct mode_key_data *, struct mode_key_tree *);
 | 
					void	mode_key_init(struct mode_key_data *, struct mode_key_tree *);
 | 
				
			||||||
enum mode_key_cmd mode_key_lookup(struct mode_key_data *, int);
 | 
					enum mode_key_cmd mode_key_lookup(struct mode_key_data *, int);
 | 
				
			||||||
 | 
					
 | 
				
			||||||
@@ -1541,7 +1540,6 @@ void	 key_bindings_add(int, int, struct cmd_list *);
 | 
				
			|||||||
void	 key_bindings_remove(int);
 | 
					void	 key_bindings_remove(int);
 | 
				
			||||||
void	 key_bindings_clean(void);
 | 
					void	 key_bindings_clean(void);
 | 
				
			||||||
void	 key_bindings_init(void);
 | 
					void	 key_bindings_init(void);
 | 
				
			||||||
void	 key_bindings_free(void);
 | 
					 | 
				
			||||||
void	 key_bindings_dispatch(struct key_binding *, struct client *);
 | 
					void	 key_bindings_dispatch(struct key_binding *, struct client *);
 | 
				
			||||||
void printflike2 key_bindings_error(struct cmd_ctx *, const char *, ...);
 | 
					void printflike2 key_bindings_error(struct cmd_ctx *, const char *, ...);
 | 
				
			||||||
void printflike2 key_bindings_print(struct cmd_ctx *, const char *, ...);
 | 
					void printflike2 key_bindings_print(struct cmd_ctx *, const char *, ...);
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user