mirror of
https://git.savannah.gnu.org/git/emacs.git
synced 2025-01-31 20:02:42 +00:00
(etags_getcwd) [WINDOWSNT]: Convert backslashes to slashes.
This commit is contained in:
parent
f8a9bac913
commit
ae178a12ea
@ -4337,6 +4337,7 @@ etags_getcwd ()
|
||||
#ifdef HAVE_GETCWD
|
||||
int bufsize = 200;
|
||||
char *path = xnew (bufsize, char);
|
||||
char *p;
|
||||
|
||||
while (getcwd (path, bufsize) == NULL)
|
||||
{
|
||||
@ -4346,7 +4347,15 @@ etags_getcwd ()
|
||||
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. */
|
||||
|
Loading…
Reference in New Issue
Block a user