[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Emacs-diffs] master 438b98e: Don't mirror slashes in convert-standard-f
From: |
Eli Zaretskii |
Subject: |
[Emacs-diffs] master 438b98e: Don't mirror slashes in convert-standard-filename on MS-Windows |
Date: |
Mon, 25 Apr 2016 08:51:42 +0000 |
branch: master
commit 438b98e5b70c55129453870b870a139c4a4a77fd
Author: Eli Zaretskii <address@hidden>
Commit: Eli Zaretskii <address@hidden>
Don't mirror slashes in convert-standard-filename on MS-Windows
* lisp/w32-fns.el (w32-convert-standard-filename): Don't mirror
slashes into backslashes. This avoids producing ugly file names,
and is deemed no longer necessary, and should certainly be
unrelated to which shell is in use.
---
etc/NEWS | 4 ++++
lisp/w32-fns.el | 10 +---------
2 files changed, 5 insertions(+), 9 deletions(-)
diff --git a/etc/NEWS b/etc/NEWS
index f964e71..eff5472 100644
--- a/etc/NEWS
+++ b/etc/NEWS
@@ -418,6 +418,10 @@ Windows NT and later you can now register any hotkey
combination. (On
Windows 9X, the previous limitations, spelled out in the Emacs manual,
still apply.)
+** `convert-standard-filename' no longer mirrors slashes on MS-Windows.
+Previously, on MS-Windows this function converted slash characters in
+file names into backslashes. It no longer does that.
+
* Installation Changes in Emacs 25.1
diff --git a/lisp/w32-fns.el b/lisp/w32-fns.el
index 4723557..690a990 100644
--- a/lisp/w32-fns.el
+++ b/lisp/w32-fns.el
@@ -200,8 +200,7 @@ certain patterns.
This function is called by `convert-standard-filename'.
Replace invalid characters and turn Cygwin names into native
-names, and also turn slashes into backslashes if the shell
-requires it (see `w32-shell-dos-semantics')."
+names."
(save-match-data
(let ((name
(if (string-match "\\`/cygdrive/\\([a-zA-Z]\\)/" filename)
@@ -216,13 +215,6 @@ requires it (see `w32-shell-dos-semantics')."
(while (string-match "[?*:<>|\"\000-\037]" name start)
(aset name (match-beginning 0) ?!)
(setq start (match-end 0)))
- ;; convert directory separators to Windows format
- ;; (but only if the shell in use requires it)
- (when (w32-shell-dos-semantics)
- (setq start 0)
- (while (string-match "/" name start)
- (aset name (match-beginning 0) ?\\)
- (setq start (match-end 0))))
name)))
(defun set-w32-system-coding-system (coding-system)
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Emacs-diffs] master 438b98e: Don't mirror slashes in convert-standard-filename on MS-Windows,
Eli Zaretskii <=