diff options
author | pgen <p.gen.progs@gmail.com> | 2020-11-06 23:05:40 +0100 |
---|---|---|
committer | pgen <p.gen.progs@gmail.com> | 2020-11-06 23:05:40 +0100 |
commit | 255863a5c6474c3be1e13655a10a4c26f4afd98f (patch) | |
tree | e0791d89c5613b06fb0b0195a417be1fe913807f | |
parent | 7565b4f672038241ef955094c03847279ae869fa (diff) |
Clean the timeout (-x|-X) management code
-rw-r--r-- | smenu.c | 13 |
1 files changed, 8 insertions, 5 deletions
@@ -7084,14 +7084,17 @@ main(int argc, char * argv[]) "[ s before selecting the current highlighted word]"); break; case WORD: - timeout_message = xcalloc(1, 4 - + strlen( - "[ s before selecting the word ") - + strlen(timeout_word)); - strcpy(timeout_message, "[ s before selecting the word \""); + { + char * s = "[ s before selecting the word \""; + + timeout_message = xcalloc(1, 4 + strlen(s) + strlen(timeout_word)); + + strcpy(timeout_message, s); strcat(timeout_message, timeout_word); strcat(timeout_message, "\"]"); + break; + } default: /* The other cases are impossible due to options analysis */ |