[Spice-devel] [PATCHv3 spice-gtk 01/14] compat: add strtok_r fallback

Marc-André Lureau mlureau at redhat.com
Thu Feb 20 06:41:32 PST 2014



----- Original Message -----
> On Mon, Feb 17, 2014 at 10:35:40PM +0100, Marc-André Lureau wrote:
> > diff --git a/gtk/glib-compat.h b/gtk/glib-compat.h
> > index c30a735..62580e2 100644
> > --- a/gtk/glib-compat.h
> > +++ b/gtk/glib-compat.h
> > @@ -1,5 +1,8 @@
> >  /* -*- Mode: C; c-basic-offset: 4; indent-tabs-mode: nil -*- */
> >  /*
> > +   Copyright (C) 2012-2014 Red Hat, Inc.
> > +   Copyright © 1998-2009 VLC authors and VideoLAN
> > +
> >     This library is free software; you can redistribute it and/or
> >     modify it under the terms of the GNU Lesser General Public
> >     License as published by the Free Software Foundation; either
> > @@ -18,6 +21,7 @@
> >  
> >  #include <glib-object.h>
> >  #include <gio/gio.h>
> > +#include "config.h"
> 
> If you add config.h here, it has to go as the very first include.

well, if you don't need any of its define, that's not really required..

> 
> >  
> >  #if !GLIB_CHECK_VERSION(2,26,0)
> >  #define G_DEFINE_BOXED_TYPE(TypeName, type_name, copy_func, free_func)
> >  G_DEFINE_BOXED_TYPE_WITH_CODE (TypeName, type_name, copy_func, free_func,
> >  {})
> 
> > diff --git a/gtk/glib-compat.c b/gtk/glib-compat.c
> > index 9ffadbb..5714173 100644
> > --- a/gtk/glib-compat.c
> > +++ b/gtk/glib-compat.c
> > @@ -1,5 +1,8 @@
> >  /* -*- Mode: C; c-basic-offset: 4; indent-tabs-mode: nil -*- */
> >  /*
> > +   Copyright (C) 2012-2014 Red Hat, Inc.
> > +   Copyright © 1998-2009 VLC authors and VideoLAN
> > +
> >     This library is free software; you can redistribute it and/or
> >     modify it under the terms of the GNU Lesser General Public
> >     License as published by the Free Software Foundation; either
> > @@ -14,6 +17,7 @@
> >     License along with this library; if not, see
> >     <http://www.gnu.org/licenses/>.
> >  */
> >  
> > +#include <string.h>
> >  #include "glib-compat.h"
> 
> and glib-compat.h needs to go before string.h here.

why?

> 
> Christophe
> 
> _______________________________________________
> Spice-devel mailing list
> Spice-devel at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/spice-devel
> 


More information about the Spice-devel mailing list