From: Sam Steingold Date: Fri, 28 Jul 2000 16:27:41 +0000 (+0000) Subject: Ange-ftp handles the output of the w32-style clients X-Git-Tag: emacs-pretest-21.0.90~2554 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=9d45313983c286609b81969c0babe73c4059b3a9;p=emacs.git Ange-ftp handles the output of the w32-style clients --- diff --git a/etc/NEWS b/etc/NEWS index 2bab6eedd19..d8d6d3ee75a 100644 --- a/etc/NEWS +++ b/etc/NEWS @@ -975,6 +975,9 @@ sign, e.g. `/foo@bar.org#666:mumble'. (This syntax comes from EFS.) *** If the new user-option `ange-ftp-try-passive-mode' is set, passive ftp mode will be used if the ftp client supports that. +*** Ange-ftp handles the output of the w32-style clients which +output ^M at the end of lines. + ** Shell script mode changes. Shell script mode (sh-script) can now indent scripts for shells diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 99c6ea145eb..2ea5ff29b7c 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,9 @@ +2000-07-28 Sam Steingold + + * net/ange-ftp.el (ange-ftp-verify-visited-file-modtime): + use `<=', not `<' to compare times! + (ange-ftp-ls): remve + 2000-07-27 Gerd Moellmann * play/cookie1.el: Add explanation of how to make cookie.el diff --git a/lisp/net/ange-ftp.el b/lisp/net/ange-ftp.el index e710540f785..d02f0577c45 100644 --- a/lisp/net/ange-ftp.el +++ b/lisp/net/ange-ftp.el @@ -2487,6 +2487,10 @@ away in the internal cache." (format "list data file %s not readable" temp)))) + ;; remove ^M inserted by the win32 ftp client + (while (re-search-forward "\r$" nil t) + (replace-match "")) + (goto-char 1) (run-hooks 'ange-ftp-before-parse-ls-hook) (if parse (ange-ftp-set-files @@ -3428,7 +3432,7 @@ system TYPE.") (let ((file-mdtm (ange-ftp-file-modtime name)) (buf-mdtm (with-current-buffer buf (visited-file-modtime)))) (or (zerop (car file-mdtm)) - (< (float-time file-mdtm) (float-time buf-mdtm)))) + (<= (float-time file-mdtm) (float-time buf-mdtm)))) (ange-ftp-real-verify-visited-file-modtime buf)))) ;;;; ------------------------------------------------------------