vis
a vi-like editor based on Plan 9's structural regular expressions
git clone https://9o.is/git/vis.git
commit 73be9c0893ab84a5b843717ddfcebb4c8e2cf380 parent c4fe388da0e5b51a52bd5475b31aa0fab75fa0dd Author: Marc André Tanner <mat@brain-dump.org> Date: Sun, 5 Apr 2015 22:41:25 +0200 Remove useless duplication of argument to exec_cmdline_command Diffstat:
| M | vis.c | | | 8 | ++------ |
1 file changed, 2 insertions(+), 6 deletions(-)
diff --git a/vis.c b/vis.c @@ -1865,12 +1865,8 @@ static bool exec_command(char type, const char *cmd) { } static void settings_apply(const char **settings) { - for (const char **opt = settings; opt && *opt; opt++) { - char *tmp = strdup(*opt); - if (tmp) - exec_cmdline_command(tmp); - free(tmp); - } + for (const char **opt = settings; opt && *opt; opt++) + exec_cmdline_command(*opt); } static bool vis_window_new(const char *file) {