[dvblast-devel] [PATCH] Use DVB API versions in #if	conditionals
    Marian Ďurkovič 
    md at bts.sk
       
    Thu Nov  5 18:50:31 CET 2009
    
    
  
Hi Christophe,
On Thu, 5 Nov 2009 17:50:08 +0100, Christophe Massiot wrote
> On Thu, Nov 05, 2009, Marian Ďurkovič wrote:
> 
> > --- dvb.c	(revision 55)
> > +++ dvb.c	(working copy)
> > @@ -741,7 +739,7 @@
> >                   i_frequency, i_srate );
> >          break;
> >  
> > -#ifdef FE_ATSC
> > +#if DVB_API_VERSION_MINOR >= 1
> 
> Are you sure about that one ? It seems wrong to me to test against the
> minor but not the major.
that part of code is already under
#if DVB_API_VERSION >= 5
#else /* !S2API */
hence if we're there, we're using API version 3 and I'm testing for 3.1
Anyway, we might certainly use the same method as in dvblastctl.c and test for
it explicitly, which would be safer:
+#define DVBAPI_VERSION ((DVB_API_VERSION)*100+(DVB_API_VERSION_MINOR))
+#if DVBAPI_VERSION >= 301
   With kind regards,
        M.
    
    
More information about the dvblast-devel
mailing list