* liece-tcp.el
authorueno <ueno>
Sun, 7 May 2000 00:50:05 +0000 (00:50 +0000)
committerueno <ueno>
Sun, 7 May 2000 00:50:05 +0000 (00:50 +0000)
(liece-tcp-rlogin-parameters): Use `socket' instead of `telnet'.
(liece-tcp-open-rlogin-stream): Don't wait for a connection.
(liece-tcp-open-rlogin-stream-as-binary): Simply wrap
`liece-tcp-open-rlogin-stream'.

lisp/ChangeLog
lisp/liece-tcp.el

index ed5486e..e43ebfb 100644 (file)
@@ -1,3 +1,11 @@
+2000-05-07   Daiki Ueno  <ueno@unixuser.org>
+
+       * liece-tcp.el
+       (liece-tcp-rlogin-parameters): Use `socket' instead of `telnet'.
+       (liece-tcp-open-rlogin-stream): Don't wait for a connection.
+       (liece-tcp-open-rlogin-stream-as-binary): Simply wrap
+       `liece-tcp-open-rlogin-stream'.
+
 2000-04-21   Daiki Ueno  <ueno@unixuser.org>
 
        * liece-ctcp.el
index b264f39..208814d 100644 (file)
@@ -93,7 +93,7 @@ The default is \"rsh\", but \"ssh\" is a popular alternative."
   :type 'file
   :group 'liece-tcp)
 
-(defcustom liece-tcp-rlogin-parameters '("telnet" "-8")
+(defcustom liece-tcp-rlogin-parameters '("socket" "-q")
   "Parameters to `liece-tcp-open-rlogin'."
   :type 'list
   :group 'liece-tcp)
@@ -198,7 +198,7 @@ Fourth arg SERVICE is name of the service desired, or an integer
   "Open a connection to SERVER using rsh."
   (let* ((service (if (stringp service)
                      service
-                  (int-to-string service)))
+                   (int-to-string service)))
         (args `(,name
                 ,buffer
                 ,liece-tcp-rlogin-program
@@ -206,33 +206,13 @@ Fourth arg SERVICE is name of the service desired, or an integer
                       (list "-l" liece-tcp-rlogin-user-name))
                 ,liece-tcp-relay-host
                 ,@liece-tcp-rlogin-parameters ,server ,service))
-        (proc (apply #'start-process args)))
-    (save-excursion
-      (set-buffer buffer)
-      (liece-tcp-wait-for-string proc "^Escape") ;; XXX
-      (beginning-of-line 2)
-      (delete-region (point-min) (point))
-      proc)))
+        (process-connection-type nil))
+    (apply #'start-process-shell-command args)))
 
 (defun liece-tcp-open-rlogin-stream-as-binary (name buffer server service)
   "Open a connection to SERVER using rsh."
-  (let* ((service (if (stringp service)
-                     service
-                   (int-to-string service)))
-        (args `(,name
-                ,buffer
-                ,liece-tcp-rlogin-program
-                ,@(if liece-tcp-rlogin-user-name
-                      (list "-l" liece-tcp-rlogin-user-name))
-                ,liece-tcp-relay-host
-                ,@liece-tcp-rlogin-parameters ,server ,service))
-        (proc (as-binary-process (apply #'start-process args))))
-    (save-excursion
-      (set-buffer buffer)
-      (liece-tcp-wait-for-string proc "^Escape") ;; XXX
-      (beginning-of-line 2)
-      (delete-region (point-min) (point))
-      proc)))
+  (as-binary-process
+   (liece-tcp-open-rlogin-stream name buffer server service)))
 
 (provide 'liece-tcp)