aboutsummaryrefslogtreecommitdiffstats
path: root/lisp/net
diff options
context:
space:
mode:
authorMichael Albinus2012-10-23 16:26:30 +0200
committerMichael Albinus2012-10-23 16:26:30 +0200
commitf7eac6d887b7768034e40f16dacbb0c8fb569417 (patch)
treec062c61a272320e947e08637c3161d3cd3c2e077 /lisp/net
parentc4132fd4f0afc4329479cf071752a7e6fa3462f2 (diff)
downloademacs-f7eac6d887b7768034e40f16dacbb0c8fb569417.tar.gz
emacs-f7eac6d887b7768034e40f16dacbb0c8fb569417.zip
* net/tramp-smb.el (tramp-smb-maybe-open-connection): Set
`tramp-chunksize' to 1. This improves the performance. (tramp-smb-wait-for-output): Add timeout to `tramp-accept-process-output' calls.
Diffstat (limited to 'lisp/net')
-rw-r--r--lisp/net/tramp-smb.el12
1 files changed, 6 insertions, 6 deletions
diff --git a/lisp/net/tramp-smb.el b/lisp/net/tramp-smb.el
index 567f8f2969a..f52129919cc 100644
--- a/lisp/net/tramp-smb.el
+++ b/lisp/net/tramp-smb.el
@@ -1677,11 +1677,11 @@ If ARGUMENT is non-nil, use it as argument for
1677 (tramp-set-connection-property 1677 (tramp-set-connection-property
1678 vec "smbserver-version" smbserver-version)))) 1678 vec "smbserver-version" smbserver-version))))
1679 1679
1680 ;; Set chunksize. Otherwise, `tramp-send-string' might 1680 ;; Set chunksize to 1. smbclient reads its input
1681 ;; try it itself. 1681 ;; character by character; if we send the string
1682 ;; at once, it is read painfully slow.
1682 (tramp-set-connection-property p "smb-share" share) 1683 (tramp-set-connection-property p "smb-share" share)
1683 (tramp-set-connection-property 1684 (tramp-set-connection-property p "chunksize" 1))
1684 p "chunksize" tramp-chunksize))
1685 1685
1686 ;; Check for the error reason. If it was due to wrong 1686 ;; Check for the error reason. If it was due to wrong
1687 ;; password, reestablish the connection. We cannot 1687 ;; password, reestablish the connection. We cannot
@@ -1717,7 +1717,7 @@ Returns nil if an error message has appeared."
1717 (while (and (not found) (not err) (memq (process-status p) '(run open))) 1717 (while (and (not found) (not err) (memq (process-status p) '(run open)))
1718 1718
1719 ;; Accept pending output. 1719 ;; Accept pending output.
1720 (tramp-accept-process-output p) 1720 (tramp-accept-process-output p 0.1)
1721 1721
1722 ;; Search for prompt. 1722 ;; Search for prompt.
1723 (goto-char (point-min)) 1723 (goto-char (point-min))
@@ -1731,7 +1731,7 @@ Returns nil if an error message has appeared."
1731 (while (and (not found) (memq (process-status p) '(run open))) 1731 (while (and (not found) (memq (process-status p) '(run open)))
1732 1732
1733 ;; Accept pending output. 1733 ;; Accept pending output.
1734 (tramp-accept-process-output p) 1734 (tramp-accept-process-output p 0.1)
1735 1735
1736 ;; Search for prompt. 1736 ;; Search for prompt.
1737 (goto-char (point-min)) 1737 (goto-char (point-min))