From a0387a0fd66954e024c926655c866a3ab80e460f Mon Sep 17 00:00:00 2001 From: Wynn Wolf Arbor Date: Wed, 18 Mar 2020 19:46:51 +0100 Subject: Remove path completion in the exec menu There are a couple of issues I found with this functionality: 1) To my knowledge, it is undocumented and extremely specific. 2) Since this function would only complete a full path (by wrapping it in quotes before passing it on), it is entirely useless when composing a command that has more than one argument. 3) The snprintf call has no check for truncation, possibly leading to the path not being quoted properly. --- search.c | 7 ------- 1 file changed, 7 deletions(-) (limited to 'search.c') diff --git a/search.c b/search.c index 591a7c3..df6f74c 100644 --- a/search.c +++ b/search.c @@ -205,13 +205,6 @@ search_match_exec(struct menu_q *menuq, struct menu_q *resultq, char *search) match_path_type(resultq, search, PATH_EXEC); } -void -search_match_path(struct menu_q *menuq, struct menu_q *resultq, char *search) -{ - TAILQ_INIT(resultq); - match_path_type(resultq, search, PATH_ANY); -} - void search_match_text(struct menu_q *menuq, struct menu_q *resultq, char *search) { -- cgit v1.2.3-2-gb3c3