anchor.diff:  ;;;; See LICENSE for licensing information.
   
   (in-package :usocket)
  +
  +(eval-when (:compile-toplevel :load-toplevel :execute)
  +  (when (find-class 'ccl::ip6-socket-address nil)
  +    (pushnew :ccl-1.11-sockets *features*)))
   
   (defun get-host-name ()
     (ccl::%stack-block ((resultbuf 256))
  
positive.code: 
  (defun get-socket-option-reuseaddr (socket)
    (ccl::int-getsockopt (ccl::socket-device socket)
                         #$SOL_SOCKET #$SO_REUSEADDR))
  
  (defun set-socket-option-reuseaddr (socket value)
    (ccl::int-setsockopt (ccl::socket-device socket)
  			 #$SOL_SOCKET #$SO_REUSEADDR value))
  
  (defun get-socket-option-broadcast (socket)
    (ccl::int-getsockopt (ccl::socket-device socket)
                         #$SOL_SOCKET #$SO_BROADCAST))
  
  (defun set-socket-option-broadcast (socket value)
    (ccl::int-setsockopt (ccl::socket-device socket)
                         #$SOL_SOCKET #$SO_BROADCAST value))
  
  (defun get-socket-option-tcp-nodelay (socket)
    (ccl::int-getsockopt (ccl::socket-device socket)
                         #$IPPROTO_TCP #$TCP_NODELAY))
  
  (defun set-socket-option-tcp-nodelay (socket value)
    (ccl::int-setsockopt (ccl::socket-device socket)
                         #$IPPROTO_TCP #$TCP_NODELAY value))
  
negative.code: 	 :text)
  	(t :binary)))
  
  #+ccl-1.11-sockets
  (defun socket-connect (host port &key (protocol :stream) element-type
                                     timeout deadline nodelay
                                     local-host local-port)
    (when (eq nodelay :if-supported)
      (setf nodelay t))
    (with-mapped-conditions ()
      (let* ((remote (when (and host port)
                       (openmcl-socket:resolve-address :host host :port port :socket-type protocol)))
             (mcl-sock (openmcl-socket:make-socket :type protocol
                                                   :address-family (openmcl-socket:socket-address-family remote)
                                                   :remote-address remote
                                                   :local-host local-host
                                                   :local-port local-port
                                                   :format (to-format element-type protocol)
                                                   :external-format ccl:*default-external-format*
                                                   :deadline deadline
                                                   :nodelay nodelay
                                                   :connect-timeout timeout
                                                   :input-timeout timeout)))
        (ecase protocol
          (:stream
           (make-stream-socket :stream mcl-sock :socket mcl-sock))
          (:datagram
           (make-datagram-socket mcl-sock :connected-p (and remote t)))))))
  
  #-ccl-1.11-sockets
  (defun socket-connect (host port &key (protocol :stream) element-type
  		       timeout deadline nodelay
                         local-host local-port)
  