changeset 10118:7e22057e9516

(ange-ftp-set-binary-mode): Ignore hash size if nil. (ange-ftp-set-ascii-mode): Likewise.
author Karl Heuer <kwzh@gnu.org>
date Tue, 06 Dec 1994 00:19:09 +0000
parents 413a1fd0f7c4
children ef5354babb14
files lisp/ange-ftp.el
diffstat 1 files changed, 6 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/ange-ftp.el	Mon Dec 05 19:34:52 1994 +0000
+++ b/lisp/ange-ftp.el	Tue Dec 06 00:19:09 1994 +0000
@@ -2690,7 +2690,9 @@
 	(ange-ftp-error host user (concat "BINARY failed: " (cdr result)))
       (save-excursion
 	(set-buffer (process-buffer (ange-ftp-get-process host user)))
-	(setq ange-ftp-hash-mark-unit (ash ange-ftp-binary-hash-mark-size -4))))))
+	(and ange-ftp-binary-hash-mark-size
+	     (setq ange-ftp-hash-mark-unit
+		   (ash ange-ftp-binary-hash-mark-size -4)))))))
 
 (defun ange-ftp-set-ascii-mode (host user)
   "Tell the ftp process for the given HOST & USER to switch to ascii mode."
@@ -2699,7 +2701,9 @@
 	(ange-ftp-error host user (concat "ASCII failed: " (cdr result)))
       (save-excursion
 	(set-buffer (process-buffer (ange-ftp-get-process host user)))
-	(setq ange-ftp-hash-mark-unit (ash ange-ftp-ascii-hash-mark-size -4))))))
+	(and ange-ftp-ascii-hash-mark-size
+	     (setq ange-ftp-hash-mark-unit
+		   (ash ange-ftp-ascii-hash-mark-size -4)))))))
 
 (defun ange-ftp-cd (host user dir)
   (let ((result (ange-ftp-send-cmd host user (list 'cd dir) "Doing CD")))