Fix minor typos etc
This commit is contained in:
parent
8cb6e6e7a8
commit
023c4b7d8a
|
@ -160,22 +160,22 @@
|
||||||
|
|
||||||
;; —————————————————
|
;; —————————————————
|
||||||
|
|
||||||
(defgeneric close-it (target con-list on-disconnect)
|
(defgeneric close-it (target &optional con-list on-disconnect)
|
||||||
(:documentation "Shut down a target's connection, forcefully.
|
(:documentation "Shut down a target's connection, forcefully.
|
||||||
Run the disconnect function as well."))
|
Run the disconnect function as well."))
|
||||||
|
|
||||||
;; CONNECTION LIST-OF-CONNECTIONS FUNCTION
|
;; CONNECTION LIST-OF-CONNECTIONS FUNCTION
|
||||||
(defmethod close-it ((con connection) connection-list on-disconnect)
|
(defmethod close-it ((con connection) &optional connection-list on-disconnect)
|
||||||
(close (con→stream con) connection-list on-disconnect))
|
(close-it (con→socket con) connection-list on-disconnect))
|
||||||
|
|
||||||
;; STREAM-USOCKET LIST-OF-CONNECTIONS FUNCTION
|
;; STREAM-USOCKET LIST-OF-CONNECTIONS FUNCTION
|
||||||
(defmethod close-it ((socket usocket:stream-usocket) connection-list on-disconnect)
|
(defmethod close-it ((socket usocket:stream-usocket) &optional connection-list on-disconnect)
|
||||||
(funcall on-disconnect socket connection-list)
|
(when connection-list (funcall on-disconnect socket connection-list))
|
||||||
(handler-case
|
(handler-case
|
||||||
(usocket:socket-close socket)
|
(usocket:socket-close socket)
|
||||||
(error (e)
|
(error (e)
|
||||||
(logger "Ignoring the error from closing connection: ~a" e)))
|
(logger "Ignoring the error from closing connection: ~a" e)))
|
||||||
(logger "Connection closed: ~A" con))
|
(logger "Connection closed: ~A" socket))
|
||||||
|
|
||||||
;; —————————————————
|
;; —————————————————
|
||||||
|
|
||||||
|
|
Ŝarĝante…
Reference in New Issue