Speedups; see ChangeLog for fine details.
[elisp/gnus.git-] / lisp / nntp.el
index 9f2be03..a123a33 100644 (file)
@@ -906,7 +906,7 @@ password contained in '~/.nntp-authinfo'."
 (defun nntp-read-server-type ()
   "Find out what the name of the server we have connected to is."
   ;; Wait for the status string to arrive.
-  (setq nntp-server-type (buffer-string))
+  (setq nntp-server-type (buffer-substring (point-min) (point-max)))
   (let ((alist nntp-server-action-alist)
        (case-fold-search t)
        entry)
@@ -956,7 +956,7 @@ password contained in '~/.nntp-authinfo'."
 
 (defun nntp-snarf-error-message ()
   "Save the error message in the current buffer."
-  (let ((message (buffer-string)))
+  (let ((message (buffer-substring (point-min) (point-max))))
     (while (string-match "[\r\n]+" message)
       (setq message (replace-match " " t t message)))
     (nnheader-report 'nntp message)