changeset 86534:1863c4982b31

(socks-original-open-network-stream): Declare as function. Move definition before use.
author Glenn Morris <rgm@gnu.org>
date Wed, 28 Nov 2007 04:04:21 +0000
parents 59b6ce989ba4
children 5b3df8d4a15b
files lisp/net/socks.el
diffstat 1 files changed, 13 insertions(+), 11 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/net/socks.el	Wed Nov 28 04:03:28 2007 +0000
+++ b/lisp/net/socks.el	Wed Nov 28 04:04:21 2007 +0000
@@ -335,6 +335,19 @@
     )
   )
 
+(declare-function socks-original-open-network-stream "socks") ; fset
+
+(defvar socks-override-functions nil
+  "*Whether to overwrite the open-network-stream function with the SOCKSified
+version.")
+
+(if (fboundp 'socks-original-open-network-stream)
+    nil				; Do nothing, we've been here already
+  (defalias 'socks-original-open-network-stream
+    (symbol-function 'open-network-stream))
+  (if socks-override-functions
+      (defalias 'open-network-stream 'socks-open-network-stream)))
+
 (defun socks-open-connection (server-info)
   (interactive)
   (save-excursion
@@ -473,17 +486,6 @@
       (setq noproxy (cdr noproxy)))
     route))
 
-(defvar socks-override-functions nil
-  "*Whether to overwrite the open-network-stream function with the SOCKSified
-version.")
-
-(if (fboundp 'socks-original-open-network-stream)
-    nil				; Do nothing, we've been here already
-  (defalias 'socks-original-open-network-stream
-    (symbol-function 'open-network-stream))
-  (if socks-override-functions
-      (defalias 'open-network-stream 'socks-open-network-stream)))
-
 (defvar socks-services-file "/etc/services")
 (defvar socks-tcp-services (make-hash-table :size 13 :test 'equal))
 (defvar socks-udp-services (make-hash-table :size 13 :test 'equal))