[usocket-cvs] r160 - usocket/trunk/backend

ehuelsmann at common-lisp.net ehuelsmann at common-lisp.net
Tue Jan 16 22:23:20 UTC 2007


Author: ehuelsmann
Date: Tue Jan 16 17:23:20 2007
New Revision: 160

Modified:
   usocket/trunk/backend/openmcl.lisp
Log:
Implement element-type support for OpenMCL.

Modified: usocket/trunk/backend/openmcl.lisp
==============================================================================
--- usocket/trunk/backend/openmcl.lisp	(original)
+++ usocket/trunk/backend/openmcl.lisp	Tue Jan 16 17:23:20 2007
@@ -42,9 +42,12 @@
 
 (defun socket-connect (host port &key (element-type 'character))
   (with-mapped-conditions ()
-     (let ((mcl-sock (openmcl-socket:make-socket :remote-host
-                                                 (host-to-hostname host)
-                                                 :remote-port port)))
+     (let ((mcl-sock
+	     (openmcl-socket:make-socket :remote-host (host-to-hostname host)
+                                         :remote-port port
+					 :format (if (subtypep element-type
+							       'character)
+						   :text :binary))))
         (openmcl-socket:socket-connect mcl-sock)
         (make-stream-socket :stream mcl-sock :socket mcl-sock))))
 



More information about the usocket-cvs mailing list