Skip to content

Commit

Permalink
Fix handling of far2medit broken in f635c2d
Browse files Browse the repository at this point in the history
  • Loading branch information
shmuz committed Dec 7, 2024
1 parent 3da08bd commit 3483ef1
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion far/src/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -388,7 +388,8 @@ int FarAppMain(int argc, char **argv)
}

// run by symlink in editor mode
if (strcmp(argv[0], "far2medit") == 0) {
auto name = strrchr(argv[0], GOOD_SLASH);
if (strcmp((name ? name+1 : argv[0]), "far2medit") == 0) {
Opt.OnlyEditorViewerUsed = Options::ONLY_EDITOR;
if (argc > 1) {
strEditViewArg = argv[argc - 1]; // use last argument
Expand Down

0 comments on commit 3483ef1

Please sign in to comment.