Commit: 391e8c2d18182fe30b61a4bfe5e56df9cc187619
Parent: 2fb5146b571c64eba976d39550ccdf49af22bc31
Author: Slawomir Bochenski <lkslawek@gmail.com>
Committer: Marcel Holtmann <marcel@holtmann.org>
Date: 2012-12-04 23:48:37
Tree: 187c958b8d7848aa06eece1dd1f0fb0d8c7ea98d

obexd: Revert API changes to mime driver read function This reverts parts of commit e0b3283e20ba885018010a6a8ae49b7c313958e8. API changes introduced before were meant to guarantee required PBAP functionality of sending application parameters header in first packet of multi-packet response. However OBEX_FL_FIT_ONE_PACKET does not serve this purpose - it is for making sure that all headers will fit fully into one packet (thus FIT_ONE_PACKET), returning error from OBEX_ObjectAddHeader() when this is not the case. Starting the body header streaming adds body header immediately to the outgoing queue, waiting for more data. Any attempts to OBEX_ObjectAddHeader() different than those with hi == OBEX_HDR_DATA and OBEX_FL_STREAM_DATA present in flags, will add new header after currently streamed body and it will be processed after ending streaming with OBEX_FL_STREAM_DATAEND. Also in this case data is memcpy'd, so no reason for any additional write_offset counting.

Diffstat

M obexd/plugins/filesystem.c | 16 +++- - - - - - - - - - - - -
M obexd/plugins/irmc.c | 6 +- - - - -
M obexd/plugins/mas.c | 4 +- - -
M obexd/plugins/pbap.c | 19 +++- - - - - - - - - - - - - - - -
M obexd/plugins/syncevolution.c | 6 +- - - - -
M obexd/src/mimetype.h | 3 +- -
M obexd/src/obex-priv.h | 1 -
M obexd/src/obex.c | 15 +++++- - - - - - - - - -

8 files changed, 15 insertions(+), 55 deletions(-)

View Full Diff | Patch