emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Emacs-diffs] master 598ff23 12/12: Use open-network-stream instead of o


From: Lars Ingebrigtsen
Subject: [Emacs-diffs] master 598ff23 12/12: Use open-network-stream instead of open-protocol-stream
Date: Sun, 14 Feb 2016 04:19:43 +0000

branch: master
commit 598ff2349eb8e3c9fc3a17d14899abe6a1e3c534
Author: Lars Ingebrigtsen <address@hidden>
Commit: Lars Ingebrigtsen <address@hidden>

    Use open-network-stream instead of open-protocol-stream
    
    * lisp/gnus/nnimap.el: Use open-network-stream instead of
    open-protocol-stream.
    
    * lisp/gnus/nntp.el: Ditto.
    
    * lisp/gnus/pop3.el: Ditto.
    
    * lisp/gnus/sieve-manage.el: Ditto.
    
    * lisp/net/network-stream.el (open-protocol-stream): Make obsolete.
---
 lisp/gnus/nnimap.el        |    9 +--------
 lisp/gnus/nntp.el          |    8 +-------
 lisp/gnus/pop3.el          |    8 +-------
 lisp/gnus/sieve-manage.el  |    2 +-
 lisp/net/gnutls.el         |    2 +-
 lisp/net/network-stream.el |    2 ++
 6 files changed, 7 insertions(+), 24 deletions(-)

diff --git a/lisp/gnus/nnimap.el b/lisp/gnus/nnimap.el
index 0e8fb66..66096ff 100644
--- a/lisp/gnus/nnimap.el
+++ b/lisp/gnus/nnimap.el
@@ -26,13 +26,6 @@
 
 ;;; Code:
 
-(eval-and-compile
-  (require 'nnheader)
-  ;; In Emacs 24, `open-protocol-stream' is an autoloaded alias for
-  ;; `make-network-stream'.
-  (unless (fboundp 'open-protocol-stream)
-    (require 'proto-stream)))
-
 (eval-when-compile
   (require 'cl))
 
@@ -424,7 +417,7 @@ textual parts.")
       (when nnimap-server-port
        (push nnimap-server-port ports))
       (let* ((stream-list
-             (open-protocol-stream
+             (open-network-stream
               "*nnimap*" (current-buffer) nnimap-address
               (nnimap-map-port (car ports))
               :type nnimap-stream
diff --git a/lisp/gnus/nntp.el b/lisp/gnus/nntp.el
index e6483c2..fa5f0e6 100644
--- a/lisp/gnus/nntp.el
+++ b/lisp/gnus/nntp.el
@@ -25,12 +25,6 @@
 
 ;;; Code:
 
-(eval-and-compile
-  ;; In Emacs 24, `open-protocol-stream' is an autoloaded alias for
-  ;; `make-network-stream'.
-  (unless (fboundp 'open-protocol-stream)
-    (require 'proto-stream)))
-
 (require 'nnheader)
 (require 'nnoo)
 (require 'gnus-util)
@@ -1266,7 +1260,7 @@ If SEND-IF-FORCE, only send authinfo to the server if the
                           (nntp-open-ssl-stream tls)
                           (nntp-open-tls-stream tls))))
                (if (assoc nntp-open-connection-function map)
-                   (open-protocol-stream
+                   (open-network-stream
                     "nntpd" pbuffer nntp-address nntp-port-number
                     :type (cadr (assoc nntp-open-connection-function map))
                     :end-of-command "^\\([2345]\\|[.]\\).*\n"
diff --git a/lisp/gnus/pop3.el b/lisp/gnus/pop3.el
index 0b1f5c8..1695bbd 100644
--- a/lisp/gnus/pop3.el
+++ b/lisp/gnus/pop3.el
@@ -34,12 +34,6 @@
 
 (eval-when-compile (require 'cl))
 
-(eval-and-compile
-  ;; In Emacs 24, `open-protocol-stream' is an autoloaded alias for
-  ;; `make-network-stream'.
-  (unless (fboundp 'open-protocol-stream)
-    (require 'proto-stream)))
-
 (require 'mail-utils)
 (defvar parse-time-months)
 
@@ -545,7 +539,7 @@ Returns the process associated with the connection."
       (erase-buffer)
       (setq pop3-read-point (point-min))
       (setq result
-           (open-protocol-stream
+           (open-network-stream
             "POP" (current-buffer) mailhost port
             :type (cond
                    ((or (eq pop3-stream-type 'ssl)
diff --git a/lisp/gnus/sieve-manage.el b/lisp/gnus/sieve-manage.el
index dd503c3..695bbd8 100644
--- a/lisp/gnus/sieve-manage.el
+++ b/lisp/gnus/sieve-manage.el
@@ -201,7 +201,7 @@ Return the buffer associated with the connection."
     (sieve-manage-erase)
     (setq sieve-manage-state 'initial)
     (destructuring-bind (proc . props)
-        (open-protocol-stream
+        (open-network-stream
          "SIEVE" buffer server port
          :type stream
          :capability-command "CAPABILITY\r\n"
diff --git a/lisp/net/gnutls.el b/lisp/net/gnutls.el
index ce44c03..904cb31 100644
--- a/lisp/net/gnutls.el
+++ b/lisp/net/gnutls.el
@@ -26,7 +26,7 @@
 
 ;; This package provides language bindings for the GnuTLS library
 ;; using the corresponding core functions in gnutls.c.  It should NOT
-;; be used directly, only through open-protocol-stream.
+;; be used directly, only through open-network-stream.
 
 ;; Simple test:
 ;;
diff --git a/lisp/net/network-stream.el b/lisp/net/network-stream.el
index 59ac299..e5557b8 100644
--- a/lisp/net/network-stream.el
+++ b/lisp/net/network-stream.el
@@ -195,6 +195,8 @@ asynchronously, if possible."
 
 ;;;###autoload
 (defalias 'open-protocol-stream 'open-network-stream)
+(define-obsolete-function-alias 'open-protocol-stream 'open-network-stream
+  "25.2")
 
 (defun network-stream-open-plain (name buffer host service parameters)
   (let ((start (with-current-buffer buffer (point)))



reply via email to

[Prev in Thread] Current Thread [Next in Thread]