Mercurial > emacs
changeset 16394:675944d1abc9
(etags_getcwd) [WINDOWSNT]: Convert backslashes to slashes.
author | Richard M. Stallman <rms@gnu.org> |
---|---|
date | Sun, 06 Oct 1996 19:50:49 +0000 |
parents | 67df8ce85ec7 |
children | c6b901f809da |
files | lib-src/etags.c |
diffstat | 1 files changed, 9 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- a/lib-src/etags.c Sun Oct 06 19:34:12 1996 +0000 +++ b/lib-src/etags.c Sun Oct 06 19:50:49 1996 +0000 @@ -4337,6 +4337,7 @@ #ifdef HAVE_GETCWD int bufsize = 200; char *path = xnew (bufsize, char); + char *p; while (getcwd (path, bufsize) == NULL) { @@ -4346,7 +4347,15 @@ path = xnew (bufsize, char); } + /* Convert backslashes to slashes. */ +#if WINDOWSNT + for (p = path; *p != '\0'; p++) + if (*p == '\\') + *p = '/'; +#endif + return path; + #else /* not HAVE_GETCWD */ #ifdef MSDOS char *p, path[MAXPATHLEN + 1]; /* Fixed size is safe on MSDOS. */