From 0e03080002ea7942ba545205f1e4127aa7c7ff1e Mon Sep 17 00:00:00 2001 From: Wim Taymans Date: Wed, 26 Aug 2015 12:46:28 +0200 Subject: Rework buffer API a little Use BufferIter and BufferBuilder instead of Packet* Make separate method to set the header so you can set it later and not only at builder init time. Add method to clear the builder if you want to abort. Add method to add fd to builder instead of in _add_fd_payload. This would make it easier to add multiple fd-payloads using data from the same fd. Pass PinosPacketFDPayload to add_fd_payload to make it symetric with the parsing code. We should be able to get the size from the VERSION passed when the builder was made. Add ideas about releasing the fds back to the server. --- doc/design.txt | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) (limited to 'doc/design.txt') diff --git a/doc/design.txt b/doc/design.txt index 4db76349..242320d3 100644 --- a/doc/design.txt +++ b/doc/design.txt @@ -71,17 +71,26 @@ Types: 0: fd-payload section + Used to send a buffer between client and server. + + : 4 bytes : id of the fd-payload : 8 bytes : offset : 8 bytes : size : 4 bytes : index of fd - 1: format change + 1: release fd-payload + + Release a fd-payload with + + : 4 bytes : the id number of the released fd-payload + + 2: format change : 1 byte : format id : 0-terminated : contains serialized format - 2: property changes + 3: property changes : 0-terminated : key : 0-terminated : value -- cgit v1.2.3