Re: [PATCH 3/4] Modify obex_write_stream logic

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Luiz,

On Wed, Jun 15, 2011, Luiz Augusto von Dentz wrote:
> So this while loop is a bit dangerous since it is supposing to be
> doing io, so what about separating the read of apparam and body in two
> callbacks, the apparam could probably be consider a metadata of you
> are actually accessing so separating those might be a good idea in the
> long term. If so then read should probably only read the data itself
> and never mix with apparams, then we have a e.g. read_apparams which
> is only called once before reading the actual data, how about that?

Seems more or less ok with me, but I'd call it get_apparams since it's
not really a stream of data like the body. FWIW, I've completely missed
the extension of the read callback to return other types of data besides
that which is contained within body headers. The original intent of it
was to only operate on the actual object body and it'd be nice if we
could get it back to that state again.

Johan
--
To unsubscribe from this list: send the line "unsubscribe linux-bluetooth" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Bluez Devel]     [Linux Wireless Networking]     [Linux Wireless Personal Area Networking]     [Linux ATH6KL]     [Linux USB Devel]     [Linux Media Drivers]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Big List of Linux Books]

  Powered by Linux