(gnus-setup-message): Setup `message-startup-parameter-alist'.
[elisp/gnus.git-] / lisp / nntp.el
index 228f50a..487c72d 100644 (file)
 
 (nnoo-declare nntp)
 
+(eval-and-compile
+  (unless (fboundp 'open-network-stream)
+    (require 'tcp)))
+
 (eval-when-compile (require 'cl))
 
 (defvoo nntp-address nil
@@ -724,7 +728,7 @@ If this variable is nil, which is the default, no timers are set.")
     (prog1
        (nntp-send-command
         "^\\.\r?\n" "NEWGROUPS"
-        (format-time-string "%y%m%d %H%M%S" (date-to-time date)))
+        (format-time-string "%y%m%d %H%M%S" (nnmail-date-to-time date)))
       (nntp-decode-text))))
 
 (deffoo nntp-request-post (&optional server)
@@ -792,7 +796,7 @@ If SEND-IF-FORCE, only send authinfo to the server if the
 The authinfo login name is taken from the user's login name and the
 password contained in '~/.nntp-authinfo'."
   (when (file-exists-p "~/.nntp-authinfo")
-    (with-temp-buffer
+    (nnheader-temp-write nil
       (insert-file-contents "~/.nntp-authinfo")
       (goto-char (point-min))
       (nntp-send-command "^3.*\r?\n" "AUTHINFO USER" (user-login-name))
@@ -821,7 +825,7 @@ password contained in '~/.nntp-authinfo'."
       (format " *server %s %s %s*"
              nntp-address nntp-port-number
              (gnus-buffer-exists-p buffer))))
-    (mm-enable-multibyte)
+    (buffer-disable-undo (current-buffer))
     (set (make-local-variable 'after-change-functions) nil)
     (set (make-local-variable 'nntp-process-wait-for) nil)
     (set (make-local-variable 'nntp-process-callback) nil)