X-Git-Url: https://git.rrq.au/?a=blobdiff_plain;f=lsp-dbus%2Flsp-dbus-marshal.lsp;h=02859d6f006a2f4d7f314521a23bee1d8a428e92;hb=1dd263248af0120fa0ab167f69f13f44adb18391;hp=81b6aa50184d682c66fa267375b3632dac125133;hpb=121167c737403e2f49231fd5704aae86850b5b38;p=rrq%2Flsp-utils.git diff --git a/lsp-dbus/lsp-dbus-marshal.lsp b/lsp-dbus/lsp-dbus-marshal.lsp index 81b6aa5..02859d6 100644 --- a/lsp-dbus/lsp-dbus-marshal.lsp +++ b/lsp-dbus/lsp-dbus-marshal.lsp @@ -191,15 +191,19 @@ (while (and (< AT (length DATA)) (setf M (unpack-data "yyyyuua(yv)" DATA AT))) (setf AT (M 1)) - (setf M (M 0 -1)) ; Drop + (setf M (M 0 -1)) ; Drop all but the headers then map to symbol keys (dotimes (i (length M 0)) (setf (M i 0) (MESSAGE-HEADERS (M i 0) 0))) + ;; Add the body, if any, keyed by "". (setf S (if (lookup 'SIGNATURE M) ($it 0) "")) (when (and (!= S "") (setf D (unpack-data S DATA AT))) (setf AT (D 1)) (extend M (list (list "" (D 0))))) - (push M OUT -1) + ;; Collate message and move to the next portion in DATA + (push M OUT -1) (setf DATA (AT DATA)) (setf AT 0) ) OUT )) + +"lsp-dbus-marshal.lsp"