diff options
| author | Marc André Tanner <mat@brain-dump.org> | 2016-01-14 19:02:49 +0100 |
|---|---|---|
| committer | Marc André Tanner <mat@brain-dump.org> | 2016-01-14 19:02:49 +0100 |
| commit | b3ff1f6b43f994312cb546d3f112d326e1e845fa (patch) | |
| tree | 14b2d9b22474c78436aac46b7da8539005bc9cc5 /vis-cmds.c | |
| parent | c71b317966e42809a580664ce372743fcedd8a06 (diff) | |
| download | vis-b3ff1f6b43f994312cb546d3f112d326e1e845fa.tar.gz vis-b3ff1f6b43f994312cb546d3f112d326e1e845fa.tar.xz | |
vis-cmds: resolve conflict with BSD getmode(3)
Closes #147
Diffstat (limited to 'vis-cmds.c')
| -rw-r--r-- | vis-cmds.c | 6 |
1 files changed, 3 insertions, 3 deletions
@@ -912,7 +912,7 @@ static bool cmd_help(Vis *vis, Filerange *range, enum CmdOpt opt, const char *ar return true; } -static enum VisMode getmode(const char *mode) { +static enum VisMode str2vismode(const char *mode) { const char *modes[] = { [VIS_MODE_NORMAL] = "normal", [VIS_MODE_OPERATOR_PENDING] = "operator-pending", @@ -931,7 +931,7 @@ static enum VisMode getmode(const char *mode) { static bool cmd_map(Vis *vis, Filerange *range, enum CmdOpt opt, const char *argv[]) { bool local = strstr(argv[0], "-") != NULL; - enum VisMode mode = getmode(argv[1]); + enum VisMode mode = str2vismode(argv[1]); const char *lhs = argv[2]; const char *rhs = argv[3]; @@ -988,7 +988,7 @@ static bool cmd_map(Vis *vis, Filerange *range, enum CmdOpt opt, const char *arg static bool cmd_unmap(Vis *vis, Filerange *range, enum CmdOpt opt, const char *argv[]) { bool local = strstr(argv[0], "-") != NULL; - enum VisMode mode = getmode(argv[1]); + enum VisMode mode = str2vismode(argv[1]); const char *lhs = argv[2]; if (mode == VIS_MODE_LAST || !lhs) { |
