Added back with-backplane
This commit is contained in:
parent
8b30811ab5
commit
665f362ce1
|
@ -127,8 +127,13 @@
|
||||||
:mechanism :sasl-plain)
|
:mechanism :sasl-plain)
|
||||||
backplane))))
|
backplane))))
|
||||||
|
|
||||||
;; (defmacro with-backplane (backplane &rest ops)
|
(defmacro with-backplane (bp-clause &rest ops)
|
||||||
;; (let ((bp-sym (gensym)))
|
(when (or (not (listp bp-clause))
|
||||||
;; `(let ((,bp-sym ,backplane))
|
(not (= 2 (length bp-clause)))
|
||||||
;; (unwind-protect (progn ,@ops)
|
(not (symbolp (car bp-clause))))
|
||||||
;; (cl-xmpp:disconnect ,bp-sym)))))
|
(error "bad backplane clause"))
|
||||||
|
(let ((bp-name (car bp-clause)))
|
||||||
|
`(let ((,bp-name ,(cadr bp-clause)))
|
||||||
|
(unwind-protect
|
||||||
|
(progn ,@ops)
|
||||||
|
(cl-xmpp:disconnect ,bp-name)))))
|
||||||
|
|
|
@ -17,4 +17,5 @@
|
||||||
#:error-p
|
#:error-p
|
||||||
#:parse-message
|
#:parse-message
|
||||||
#:handle-message
|
#:handle-message
|
||||||
#:backplane-connect))
|
#:backplane-connect
|
||||||
|
#:with-backplane))
|
||||||
|
|
Loading…
Reference in New Issue