[Spice-devel] [PATCH 05/14] reds: Derive VDIPortReadBuf from RedPipeItem

Jonathon Jongsma jjongsma at redhat.com
Wed Apr 13 15:54:21 UTC 2016


On Tue, 2016-04-12 at 10:37 +0200, Christophe Fergeau wrote:
> Hey,
> 
> On Mon, Apr 11, 2016 at 04:02:20PM -0500, Jonathon Jongsma wrote:
> > On Thu, 2016-04-07 at 17:11 -0500, Jonathon Jongsma wrote:
> > > From: Christophe Fergeau <cfergeau at redhat.com>
> > > 
> > > Since RedPipeItem is already refcounted, this allows to remove various
> > > layers of ref/unref helpers from reds.c, and use the generic
> > > red_pipe_item_{ref, unref} instead.
> > 
> > Hmm, I don't know if I like making this a RedPipeItem just to get the
> > refcounting. It seems like it would be better to simply return an actual
> > pipe
> > item (e.g. AgentDataPipeItem) rather than VDIReadBuf from
> > read_one_msg_from_device(). That would match the other char device
> > implementations more closely as well...
> 
> Looks like a bigger change, but from a quick look it would probably make
> more sense indeed.
> 
> Christophe


So I did some experimenting here and decided that it was too invasive to do
here. The current approach is OK, and we can revisit this after the refactory
branch is merged if we want.




More information about the Spice-devel mailing list