mirror of
https://github.com/rkd77/elinks.git
synced 2024-12-04 14:46:47 -05:00
Used add_shell_quoted_to_string instead of enclosing the text with '"'.
The code works both with copiousoutput and without it. [ Part 1/2 of commitc25c41bd18
on the witekfl branch. I'm leaving out the part that depends on commit469481b272
, which is not yet safe to apply. --KON ]
This commit is contained in:
parent
b3fa9a7019
commit
026e56d539
@ -822,9 +822,8 @@ subst_file(unsigned char *prog, unsigned char *file)
|
|||||||
|
|
||||||
if (init_string(&s)) {
|
if (init_string(&s)) {
|
||||||
add_to_string(&s, "/bin/cat ");
|
add_to_string(&s, "/bin/cat ");
|
||||||
add_char_to_string(&s, '"');
|
add_shell_quoted_to_string(&s, file, strlen(file));
|
||||||
add_to_string(&s, file);
|
add_to_string(&s, " | ");
|
||||||
add_to_string(&s, "\" | ");
|
|
||||||
add_string_to_string(&s, &name);
|
add_string_to_string(&s, &name);
|
||||||
done_string(&name);
|
done_string(&name);
|
||||||
return s.source;
|
return s.source;
|
||||||
|
Loading…
Reference in New Issue
Block a user