diff options
author | Kjell Wooding <kjell@cvs.openbsd.org> | 2005-11-20 18:47:12 +0000 |
---|---|---|
committer | Kjell Wooding <kjell@cvs.openbsd.org> | 2005-11-20 18:47:12 +0000 |
commit | 705421d2e1c7b89d0d15f6cc801d59c7ecee3342 (patch) | |
tree | 45298aacfe2deb5384d3af4b8b83aa724f943475 | |
parent | 5edbb1a26ab00ad05a30182a83cf4bb42af50dd1 (diff) |
#ifdef NO_DIR can go too. From Han Boetes.
-rw-r--r-- | usr.bin/mg/dir.c | 4 | ||||
-rw-r--r-- | usr.bin/mg/fileio.c | 9 | ||||
-rw-r--r-- | usr.bin/mg/funmap.c | 6 | ||||
-rw-r--r-- | usr.bin/mg/main.c | 4 |
4 files changed, 6 insertions, 17 deletions
diff --git a/usr.bin/mg/dir.c b/usr.bin/mg/dir.c index 45b19382137..2383d711681 100644 --- a/usr.bin/mg/dir.c +++ b/usr.bin/mg/dir.c @@ -1,4 +1,4 @@ -/* $OpenBSD: dir.c,v 1.14 2005/08/09 00:53:48 kjell Exp $ */ +/* $OpenBSD: dir.c,v 1.15 2005/11/20 18:47:11 kjell Exp $ */ /* This file is in the public domain. */ @@ -11,7 +11,6 @@ #include "def.h" -#ifndef NO_DIR char *wdir; static char cwd[NFILEN]; @@ -64,4 +63,3 @@ showcwdir(int f, int n) ewprintf("Current directory: %s", wdir); return (TRUE); } -#endif diff --git a/usr.bin/mg/fileio.c b/usr.bin/mg/fileio.c index deb2a2a9838..2e3ddeb469e 100644 --- a/usr.bin/mg/fileio.c +++ b/usr.bin/mg/fileio.c @@ -1,4 +1,4 @@ -/* $OpenBSD: fileio.c,v 1.64 2005/11/20 04:16:34 kjell Exp $ */ +/* $OpenBSD: fileio.c,v 1.65 2005/11/20 18:47:11 kjell Exp $ */ /* This file is in the public domain. */ @@ -231,9 +231,8 @@ fbackupfile(const char *fn) } /* - * The string "fn" is a file name. - * Perform any required appending of directory name or case adjustments. - * If NO_DIR is not defined, the same file should be referred to even if the + * The string "fn" is a file name. Perform any required appending of directory + * name or case adjustments. The same file should be referred to even if the * working directory changes. */ #ifdef SYMBLINK @@ -244,9 +243,7 @@ fbackupfile(const char *fn) #endif #endif #include <pwd.h> -#ifndef NO_DIR extern char *wdir; -#endif char * adjustname(const char *fn) diff --git a/usr.bin/mg/funmap.c b/usr.bin/mg/funmap.c index 75770645fce..d24dcb9b912 100644 --- a/usr.bin/mg/funmap.c +++ b/usr.bin/mg/funmap.c @@ -1,4 +1,4 @@ -/* $OpenBSD: funmap.c,v 1.20 2005/11/20 04:17:25 kjell Exp $ */ +/* $OpenBSD: funmap.c,v 1.21 2005/11/20 18:47:11 kjell Exp $ */ /* * Copyright (c) 2001 Artur Grabowski <art@openbsd.org>. All rights reserved. * @@ -63,9 +63,7 @@ static struct funmap functnames[] = { {executemacro, "call-last-kbd-macro",}, #endif /* !NO_MACRO */ {capword, "capitalize-word",}, -#ifndef NO_DIR {changedir, "cd",}, -#endif /* !NO_DIR */ {copyregion, "copy-region-as-kill",}, #ifdef REGEX {cntmatchlines, "count-matches",}, @@ -155,9 +153,7 @@ static struct funmap functnames[] = { {backline, "previous-line",}, {prevwind, "previous-window",}, {spawncli, "push-shell",}, -#ifndef NO_DIR {showcwdir, "pwd",}, -#endif /* !NO_DIR */ {queryrepl, "query-replace",}, #ifdef REGEX {replstr, "replace-string",}, diff --git a/usr.bin/mg/main.c b/usr.bin/mg/main.c index afdbe7e99a8..049cbc26881 100644 --- a/usr.bin/mg/main.c +++ b/usr.bin/mg/main.c @@ -1,4 +1,4 @@ -/* $OpenBSD: main.c,v 1.46 2005/11/20 03:24:17 deraadt Exp $ */ +/* $OpenBSD: main.c,v 1.47 2005/11/20 18:47:11 kjell Exp $ */ /* This file is in the public domain. */ @@ -77,9 +77,7 @@ main(int argc, char **argv) errx(1, "Unknown function `%s'", init_fcn_name); vtinit(); /* Virtual terminal. */ -#ifndef NO_DIR dirinit(); /* Get current directory. */ -#endif /* !NO_DIR */ edinit(init_fcn); /* Buffers, windows. */ ttykeymapinit(); /* Symbols, bindings. */ |