[Spice-devel] [PATCH 5/9] server: dispatcher_init/dispatcher_new

Christophe Fergeau cfergeau at redhat.com
Fri Oct 23 08:23:30 PDT 2015


On Thu, Oct 22, 2015 at 09:51:09AM -0400, Frediano Ziglio wrote:
> > I tried to do these changes. Unfortunately after this setting
> > red_dispatcher_new
> > calls some callbacks which require qxl->st->dispatcher to be set,
> > specifically
> > 
> >     qxl->st->qif->attache_worker(qxl, &red_dispatcher->base);
> >     qxl->st->qif->set_compression_level(qxl, calc_compression_level());
> > 
> > I would suggest either
> > - move these line in the caller;
> > - ditch the patch.
> >  
> 
> Tried to move the lines in the caller (spice_server_add_interface in server/reds.c),
> they called a call_compression_level function which is defined in red_dispatcher.c.
> Made the function not static and exported but one of the lines access qxl->st->dispatcher
> which is not defined entirely.

Maybe there could  have an additional red_dispatcher_attach(qxl); call
or whatever doing the additional setup after _new() has been called?

I don't mind dropping this, unless some patches later on make much more
sense with a _new() method rather than an _init().

Christophe
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: not available
URL: <http://lists.freedesktop.org/archives/spice-devel/attachments/20151023/64dc3abf/attachment-0001.sig>


More information about the Spice-devel mailing list