]> git.eshelyaron.com Git - emacs.git/commitdiff
Adapt browse-url.el to improvements in Cygwin's cygstart utility.
authorKen Brown <kbrown@cornell.edu>
Fri, 13 Apr 2012 15:15:42 +0000 (11:15 -0400)
committerKen Brown <kbrown@cornell.edu>
Fri, 13 Apr 2012 15:15:42 +0000 (11:15 -0400)
* lisp/net/browse-url.el (browse-url-file-url): Remove Cygwin hack;
this is no longer needed now that cygstart understands file://
URLs.
(browse-url-filename-alist): For the same reason, don't modify
file:// URLs on Cygwin.

lisp/ChangeLog
lisp/net/browse-url.el

index 0a3f3b8f8555e50c9057e025266d51e0b9760072..b820ef5a056a6da1c599578fd77f79c6f49830f1 100644 (file)
@@ -1,3 +1,11 @@
+2012-04-13  Ken Brown  <kbrown@cornell.edu>
+
+       * net/browse-url.el (browse-url-file-url): Remove Cygwin hack;
+       this is no longer needed now that cygstart understands file://
+       URLs.
+       (browse-url-filename-alist): For the same reason, don't modify
+       file:// URLs on Cygwin.
+
 2012-04-13  Stefan Monnier  <monnier@iro.umontreal.ca>
 
        * emulation/cua-base.el (cua--pre-command-handler-1): Don't activate
index 0bfc8eda3b1510ae08b6ab43cdf1b1c12d7faa44..62c0e317a8187bc1905d344296c940a3803cf0e8 100644 (file)
@@ -467,7 +467,7 @@ commands reverses the effect of this variable.  Requires Netscape version
     ;; it in anonymous cases.  If it's not anonymous the next regexp
     ;; applies.
     ("^/\\([^:@]+@\\)?\\([^:]+\\):/*" . "ftp://\\1\\2/")
-    ,@(if (memq system-type '(windows-nt ms-dos cygwin))
+    ,@(if (memq system-type '(windows-nt ms-dos))
           '(("^\\([a-zA-Z]:\\)[\\/]" . "file:///\\1/")
             ("^[\\/][\\/]+" . "file://")))
     ("^/+" . "file:///"))
@@ -724,12 +724,6 @@ interactively.  Turn the filename into a URL with function
 (defun browse-url-file-url (file)
   "Return the URL corresponding to FILE.
 Use variable `browse-url-filename-alist' to map filenames to URLs."
-  ;; De-munge Cygwin filenames before passing them to Windows browser.
-  (if (eq system-type 'cygwin)
-      (let ((winfile (with-output-to-string
-                      (call-process "cygpath" nil standard-output
-                                    nil "-m" file))))
-       (setq file (substring winfile 0 -1))))
   (let ((coding (and (default-value 'enable-multibyte-characters)
                     (or file-name-coding-system
                         default-file-name-coding-system))))