mirror of
https://github.com/fmang/opustags.git
synced 2025-10-19 20:30:02 +02:00
Add -- to the editor’s command line
While that may not be supported by all editors, that should be supported by most and avoids ambiguous option interpretation.
This commit is contained in:
@@ -239,7 +239,7 @@ std::string ot::shell_escape(std::string_view word)
|
||||
|
||||
void ot::run_editor(std::string_view editor, std::string_view path)
|
||||
{
|
||||
std::string command = std::string(editor) + " " + shell_escape(path);
|
||||
std::string command = std::string(editor) + " -- " + shell_escape(path);
|
||||
int status = system(command.c_str());
|
||||
|
||||
if (status == -1)
|
||||
|
Reference in New Issue
Block a user