]> code.delx.au - gnu-emacs/blobdiff - lisp/w32-fns.el
Merge from origin/emacs-25
[gnu-emacs] / lisp / w32-fns.el
index 876df875b1b4bf13496e9eddacad61fef8c86dbe..690a99020878aa3eaf61f1dd3f8a6091f005c507 100644 (file)
@@ -1,6 +1,6 @@
 ;;; w32-fns.el --- Lisp routines for 32-bit Windows
 
-;; Copyright (C) 1994, 2001-2015 Free Software Foundation, Inc.
+;; Copyright (C) 1994, 2001-2016 Free Software Foundation, Inc.
 
 ;; Author: Geoff Voelker <voelker@cs.washington.edu>
 ;; Keywords: internal
@@ -44,7 +44,7 @@
   (or (bound-and-true-p shell-file-name)
       (getenv "ESHELL")
       (getenv "SHELL")
-      (and (w32-using-nt) "cmd.exe")
+      (and (fboundp 'w32-using-nt) (w32-using-nt) "cmd.exe")
       "command.com"))
 
 (defun w32-system-shell-p (shell-name)
@@ -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)