diff options
| author | throwawayaccount12345-1 <77868642+throwawayaccount12345-1@users.noreply.github.com> | 2021-11-05 13:43:18 -0300 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2021-11-05 13:43:18 -0300 |
| commit | 3e580b185c50f655aba0b9664460520e916fbb1e (patch) | |
| tree | ca49dc2018947b89aaae53a0456e1b4dfcf89396 /src/string_utils.cc | |
| parent | a70dbda54c16f327d6f6e7fa5573e3751f7fda47 (diff) | |
rc/tools/make.kak: quote "${kak_opt_makecmd}"
As per man page eval(1p):
> The eval utility shall construct a command by concatenating arguments together,
> separating each with a `<space>` character. The constructed command shall be
> read and executed by the shell.
When not quoting `$kak_opt_makecmd` in the eval, the variable is split by
newlines and spaces and then joined by spaces to form the command. If there
were newlines in `$kak_opt_makecmd`, the command would be malformed.
To reproduce:
```kak
set-option global makecmd "
echo foo
echo bar"
make a b c
```
Expected output in the `*make*` buffer:
```
foo
bar a b c
```
Actual output:
```
foo echo bar a b c
```
This patch fixes this.
Diffstat (limited to 'src/string_utils.cc')
0 files changed, 0 insertions, 0 deletions
