From 1ae1909641c989f894625b758fb15487ffc6c560 Mon Sep 17 00:00:00 2001 From: rlar Date: Sat, 28 Jun 2014 17:35:42 +0200 Subject: [PATCH] inp_sort_params(), simplify, "%s" does work for the empty string --- src/frontend/inpcom.c | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/src/frontend/inpcom.c b/src/frontend/inpcom.c index 7472a0443..974641079 100644 --- a/src/frontend/inpcom.c +++ b/src/frontend/inpcom.c @@ -3847,11 +3847,7 @@ inp_sort_params(struct line *start_card, struct line *end_card, struct line *car end--; } *str_ptr = '\0'; - if (*end != '\0') { - new_str = tprintf("%s{%s}%s", curr_line, param_names[i], end); - } else { - new_str = tprintf("%s{%s}", curr_line, param_names[i]); - } + new_str = tprintf("%s{%s}%s", curr_line, param_names[i], end); str_ptr = new_str + strlen(curr_line) + strlen(param_names[i]); tfree(ptr->li_line);