# HG changeset patch # User Richard M. Stallman # Date 767734466 0 # Node ID 6fa038c33a0fbdaad70c8d3212f02745ff257f6b # Parent 6b202e759f695680307c7e766fbdfd8b37f22526 [MSDOS]: #include for the following. [MSDOS] (etags_getcwd): Define simple MSDOS version without spawning a shell. diff -r 6b202e759f69 -r 6fa038c33a0f lib-src/etags.c --- a/lib-src/etags.c Sat Apr 30 19:10:37 1994 +0000 +++ b/lib-src/etags.c Sat Apr 30 19:34:26 1994 +0000 @@ -32,6 +32,7 @@ #ifdef MSDOS #include +#include #endif /* MSDOS */ #ifdef HAVE_CONFIG_H @@ -3123,6 +3124,21 @@ return result; } +#ifdef MSDOS +char * +etags_getcwd () +{ + char *p, cwd[MAXPATHLEN + 1]; /* Fixed size is safe on MSDOS. */ + getwd (cwd); + p = cwd; + while (*p) + if (*p == '\\') + *p++ = '/'; + else + *p++ = tolower (*p); + return strdup (cwd); +} +#else /* not MSDOS */ /* Does the same work as the system V getcwd, but does not need to guess buffer size in advance. Included mostly for compatibility. */ char * @@ -3155,6 +3171,7 @@ return buf; } +#endif /* not MSDOS */ /* Return a newly allocated string containing the filename of FILE relative to the absolute directory DIR (which