From: Ralph Corderoy Date: Sat, 2 Sep 2017 23:22:18 +0000 (+0100) Subject: geteditor.c: Hard-code the default, "vi". X-Git-Url: https://diplodocus.org/git/nmh/commitdiff_plain/39a12997e2d7705a2760a1198932f23f4e590aab?ds=inline;hp=55a31c2eec8e219a297ba7fa2f11c3f5108b0fe2 geteditor.c: Hard-code the default, "vi". It was the only use of the DEFAULT_EDITOR macro, so that can be deleted. --- diff --git a/h/nmh.h b/h/nmh.h index 07f7240b..7336c24b 100644 --- a/h/nmh.h +++ b/h/nmh.h @@ -83,4 +83,3 @@ ssize_t getline(char **lineptr, size_t *n, FILE *stream); */ #define DEFAULT_PAGER "more" -#define DEFAULT_EDITOR "vi" diff --git a/sbr/geteditor.c b/sbr/geteditor.c index 80602af3..9889a5e3 100644 --- a/sbr/geteditor.c +++ b/sbr/geteditor.c @@ -20,7 +20,7 @@ get_default_editor(void) if (!(str = context_find("editor")) && !(str = getenv("VISUAL")) && !(str = getenv("EDITOR"))) { - str = DEFAULT_EDITOR; + str = "vi"; } return (default_editor = str);