Skip to content
Myr

application: exec: error out on non-spec compliant quoting (#585)

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Broken desktop files, with non-spec compliant quoting (quotes appear in the middle of an argument), is the source of an endless number of bug reports. At least print an error message, and bail out, when the user tries to execute such a desktop file.

authored by Daniel Eklöf · committed by markstos · parent 35ce4b5 · Browse files · 2 files+9 added−0 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Trailers

  • Co-authored-by: Mark Stosberg <mark@stosberg.com>
  • Reviewed-on: https://codeberg.org/dnkl/fuzzel/pulls/585
  • Co-authored-by: Daniel Eklöf <daniel@ekloef.se>
  • Co-committed-by: Daniel Eklöf <daniel@ekloef.se>

Diff stats

2 files+9 added−0 removed

  • other:+9 added−0 removed

2 files+9 added−0 removed

modified:application.c+7 added
77 unmodified lines
78 *79 * Room for improvement: log warning/error message if80 * the previous character is not a space.81 */8283 if (search_start != p) {84 LOG_ERR("command line contains non-specification-compliant "85 "quoting (arguments must be quoted in whole)");86 goto err;87 }8889 open_quote = *p;90 search_start = p + 1;91 } else if (*p == open_quote) {92 /*
305 unmodified lines
modified:CHANGELOG.md+2 added
64 unmodified lines
65 ([#553][553]).66* Use the width of 'o' instead of 'W' when calculating the window67 width ([#560][560]).68* Default icon theme from `hicolor` to `default`.69* Error out (with an appropriate error message) if the command line we70 attempt to execute has non-specification-compliant quoting.7172[560]: https://codeberg.org/dnkl/fuzzel/issues/5607374
930 unmodified lines