anchor.diff:          (:active
            (assert (xnor local-host local-port))
            (assert (xnor remote-host remote-port))
  -         (setf socket (create-socket :address-family :internet :type :stream
  -                                     :connect :active :ipv6 ipv6
  -                                     :external-format ef))
  -         (when keepalive (set-socket-option socket :keep-alive :value t))
  -         (when nodelay (set-socket-option socket :tcp-nodelay :value t))
  -         (when local-host
  -           (setf address (convert-or-lookup-inet-address local-host ipv6))
  -           (bind-address socket address :port local-port
  -                         :reuse-address reuse-address))
  -         (when remote-host
  -           (setf address (convert-or-lookup-inet-address remote-host ipv6))
  -           (connect socket address :port remote-port)))
  +         (%close-on-error (socket)
  +           (setf socket (create-socket :address-family :internet :type :stream
  +                                       :connect :active :ipv6 ipv6
  +                                       :external-format ef))
  +           (when keepalive (set-socket-option socket :keep-alive :value t))
  +           (when nodelay (set-socket-option socket :tcp-nodelay :value t))
  +           (when local-host
  +             (setf address (convert-or-lookup-inet-address local-host ipv6))
  +             (bind-address socket address :port local-port
  +                           :reuse-address reuse-address))
  +           (when remote-host
  +             (setf address (convert-or-lookup-inet-address remote-host ipv6))
  +             (connect socket address :port remote-port))))
           (:passive
            (assert (xnor local-host local-port))
  -         (setf socket (create-socket :address-family :internet :type :stream
  -                                     :connect :passive :ipv6 ipv6))
  -         (when local-host
  -           (setf address (convert-or-lookup-inet-address local-host ipv6))
  -           (bind-address socket address :port local-port
  -                         :reuse-address reuse-address)
  -           (socket-listen socket :backlog backlog)))))
  +         (%close-on-error (socket)
  +           (setf socket (create-socket :address-family :internet :type :stream
  +                                       :connect :passive :ipv6 ipv6))
  +           (when local-host
  +             (setf address (convert-or-lookup-inet-address local-host ipv6))
  +             (bind-address socket address :port local-port
  +                           :reuse-address reuse-address)
  +             (socket-listen socket :backlog backlog))))))
       (values socket)))
   
   (declaim (inline %make-local-stream-socket))
  
positive.code:       (ecase connect
          (:active
           (assert remote-filename)
           (setf socket (create-socket :address-family :local :type :stream
                                       :connect :active :external-format ef))
           (when local-filename (bind-address socket (make-address local-filename)))
           (connect socket (make-address remote-filename)))
          (:passive
           (assert local-filename)
           (setf socket (create-socket :address-family :local :type :stream
                                       :connect :passive))
           (bind-address socket (make-address local-filename))
           (socket-listen socket :backlog backlog))))
      (values socket)))
  
  (declaim (inline %make-internet-datagram-socket))
  
negative.code:     (make-instance socket-class :family address-family
                     :external-format external-format)))
  
  (defmacro %close-on-error ((obj) &body body)
    (with-gensyms ($flag$)
      `(let ((,$flag$ t))
         (unwind-protect (multiple-value-prog1 (progn ,@body) (setf ,$flag$ nil))
           (when (and ,obj ,$flag$) (close ,obj :abort t))))))
  
  (declaim (inline %make-internet-stream-socket))
  (defun %make-internet-stream-socket (args connect ipv6 ef)
    (let (socket address)
  