aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGlenn Morris2013-08-16 00:13:48 -0700
committerGlenn Morris2013-08-16 00:13:48 -0700
commite8bedf5a8836cdcb74b881eadba12564ca8de9ef (patch)
treec66845a73b2e610f401198456b4585ff75a77da4
parent58c4682f76b2417640a6789aaa8ee0ad9ab4bad9 (diff)
downloademacs-e8bedf5a8836cdcb74b881eadba12564ca8de9ef.tar.gz
emacs-e8bedf5a8836cdcb74b881eadba12564ca8de9ef.zip
* lisp/net/ange-ftp.el (ange-ftp-good-msgs, ange-ftp-get-pwd):
Handle "Remote Directory" response of some clients. Fixes: debbugs:15058
-rw-r--r--lisp/ChangeLog3
-rw-r--r--lisp/net/ange-ftp.el8
2 files changed, 8 insertions, 3 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog
index c35252b184c..9e77d51c815 100644
--- a/lisp/ChangeLog
+++ b/lisp/ChangeLog
@@ -1,5 +1,8 @@
12013-08-16 Glenn Morris <rgm@gnu.org> 12013-08-16 Glenn Morris <rgm@gnu.org>
2 2
3 * net/ange-ftp.el (ange-ftp-good-msgs, ange-ftp-get-pwd):
4 Handle "Remote Directory" response of some clients. (Bug#15058)
5
3 * emacs-lisp/bytecomp.el (byte-compile-make-variable-buffer-local): 6 * emacs-lisp/bytecomp.el (byte-compile-make-variable-buffer-local):
4 Tweak warning. (Bug#14926) 7 Tweak warning. (Bug#14926)
5 8
diff --git a/lisp/net/ange-ftp.el b/lisp/net/ange-ftp.el
index c3adb7208e9..b8e279be91b 100644
--- a/lisp/net/ange-ftp.el
+++ b/lisp/net/ange-ftp.el
@@ -1,7 +1,6 @@
1;;; ange-ftp.el --- transparent FTP support for GNU Emacs 1;;; ange-ftp.el --- transparent FTP support for GNU Emacs
2 2
3;; Copyright (C) 1989-1996, 1998, 2000-2013 Free Software Foundation, 3;; Copyright (C) 1989-1996, 1998, 2000-2013 Free Software Foundation, Inc.
4;; Inc.
5 4
6;; Author: Andy Norman (ange@hplb.hpl.hp.com) 5;; Author: Andy Norman (ange@hplb.hpl.hp.com)
7;; Maintainer: FSF 6;; Maintainer: FSF
@@ -700,7 +699,7 @@ parenthesized expressions in REGEXP for the components (in that order)."
700 "Regular expression matching the start of a multiline FTP reply.") 699 "Regular expression matching the start of a multiline FTP reply.")
701 700
702(defvar ange-ftp-good-msgs 701(defvar ange-ftp-good-msgs
703 "^220 \\|^230 \\|^226 \\|^25. \\|^221 \\|^200 \\|^[Hh]ash mark" 702 "^220 \\|^230 \\|^226 \\|^25. \\|^221 \\|^200 \\|^[Hh]ash mark\\|^Remote directory:"
704 "Regular expression matching FTP \"success\" messages.") 703 "Regular expression matching FTP \"success\" messages.")
705 704
706;; CMS and the odd VMS machine say 200 Port rather than 200 PORT. 705;; CMS and the odd VMS machine say 200 Port rather than 200 PORT.
@@ -3021,6 +3020,9 @@ and LINE is the relevant success or fail line from the FTP-client."
3021 (if (car result) 3020 (if (car result)
3022 (save-match-data 3021 (save-match-data
3023 (and (or (string-match "\"\\([^\"]*\\)\"" line) 3022 (and (or (string-match "\"\\([^\"]*\\)\"" line)
3023 ;; Some clients cache the value and return it in
3024 ;; this way without asking the server. (Bug#15058)
3025 (string-match "^Remote directory: \\(.*\\)" line)
3024 (string-match " \\([^ ]+\\) " line)) ; stone-age VMS servers! 3026 (string-match " \\([^ ]+\\) " line)) ; stone-age VMS servers!
3025 (setq dir (match-string 1 line))))) 3027 (setq dir (match-string 1 line)))))
3026 (cons dir line))) 3028 (cons dir line)))