[Spice-devel] [PATCH spice-server] Fix core-interface type regression

Frediano Ziglio fziglio at redhat.com
Thu Oct 27 09:39:50 UTC 2016


> 
> On Wed, Oct 26, 2016 at 10:08:09AM +0100, Frediano Ziglio wrote:
> > This was introduced with 96e94c6f32d4345ea25ef7a474fbd92de03b38ad
> > (Convert RedChannel hierarchy to GObject).
> > The type for "core-interface" property should be
> > SpiceCoreInterfaceInternal, not SpiceCoreInterface.
> > 
> > Signed-off-by: Frediano Ziglio <fziglio at redhat.com>
> > ---
> >  server/dummy-channel.c | 5 +++--
> >  1 file changed, 3 insertions(+), 2 deletions(-)
> > 
> > diff --git a/server/dummy-channel.c b/server/dummy-channel.c
> > index c43221b..61a8d95 100644
> > --- a/server/dummy-channel.c
> > +++ b/server/dummy-channel.c
> > @@ -50,7 +50,8 @@ static void dummy_watch_update_mask(SpiceWatch *watch,
> > int event_mask)
> >  {
> >  }
> >  
> > -static SpiceWatch *dummy_watch_add(int fd, int event_mask, SpiceWatchFunc
> > func, void *opaque)
> > +static SpiceWatch *dummy_watch_add(const SpiceCoreInterfaceInternal
> > *iface,
> > +                                   int fd, int event_mask, SpiceWatchFunc
> > func, void *opaque)
> >  {
> >      return NULL; // apparently allowed?
> >  }
> > @@ -60,7 +61,7 @@ static void dummy_watch_remove(SpiceWatch *watch)
> >  }
> >  
> >  // TODO: actually, since I also use channel_client_dummym, no need for
> >  core. Can be NULL
> 
> Feel free to fix the "dummym" typo there in that commit as well. Looks
> like passing a NULL core-interface would fix this bug too, do you know
> why this is a TODO and not done now? Just curious, I'm fine with
> Acked-by: Christophe Fergeau <cfergeau at redhat.com>
> for now.
> 
> Christophe
> 

The TODO question is a bit OT with this patch.
I think it's a really old comment just (correctly) moved here.
I'm planning (after some possible way of testing) to remove this
entirely DummyChannel stuff so I don't care much.

Frediano

> > -static const SpiceCoreInterface dummy_core = {
> > +static const SpiceCoreInterfaceInternal dummy_core = {
> >      .watch_update_mask = dummy_watch_update_mask,
> >      .watch_add = dummy_watch_add,
> >      .watch_remove = dummy_watch_remove,



More information about the Spice-devel mailing list