Re: SourceCaps (was: vdr 1.3 SUSE RPMs)

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Carsten, 
Hi Klaus,

I will prepare a patch that doesn't change VDR's default behaviour. You are 
absolutly right about that.

On Sunday 19 June 2005 13:49, Carsten Koch wrote:
> Klaus Schmidinger wrote:
> ...
>
> > it would appear to me that this won't work if no SourceCaps are set.
> > If you really want this to go into VDR then you need to make sure
> > a system that does not have SourceCaps set (which IMHO will be the
> > majority) will still work.
>
> I fully agree that the default must be "source is provided".
>
> I suppose a global flag "SourceCapsSet" which is initialized
> to false and which is set true true by ParseSourceCaps should
> do the trick?

I will try a per device flag approach, which will give a bit more flexibility.

> After all, this is Christian's patch, so I do not want to take
> it over unless Christian wants me to.
> Christian, are you reading this?
> Would you like to fix your patch so Klaus can accept it?

Yes, I will try, I will post to the list so that you can review it, when it is 
ready.

> > BTW: what's with this:
> >
> > diff -ru /hetis/home/cko/VDR/sources.c VDR/sources.c
> > --- /hetis/home/cko/VDR/sources.c    2004-12-26 12:58:52.000000000 +0100
> > +++ VDR/sources.c    2005-04-05 22:12:55.421326944 +0200
> > @@ -68,7 +68,7 @@
> >       int pos = 0;
> >       bool dot = false;
> >       bool neg = false;
> > -     while (*++s) {
> > +     while (*++s && !isblank(*s)) {
> >             switch (toupper(*s)) {
> >               case '0' ... '9': pos *= 10;
> >                                 pos += *s - '0';
> >
> > Obviously this has nothing to do with SourceCaps - but what's it for
> > then?
>
> I do not know.
> My guess is that Christian needed this in a previous version of
> cSetup::ParseSourceCaps? After all, cSetup::ParseSourceCaps is
> calling cSource::FromString.
> I believe this hunk can safely be omitted.

No, tried this, but omitting breaks the patch. The reason for this small patch 
is that without the !isblank(*s) term the cSourceFrom::FromString won't 
accept a list of source ssepareted by white spaces, which is need to keep the 
parsing simple. For expample parsing a string like "SourceCaps = 1 S13.0E 
S19.2E S5.0E" will lead to three cSource::FormString(...) calls with this 
input strings
"S13.0E S19.2E S5.0E"
"S19.E S5.0E"
"S5.0E"
Without the !isblank(*s) term the return value would be stNone, which is not 
exactly what i need ;-)
But if you dislike this behaviour, i will change the Parse function and leave 
cSource untouched?

Have a nice day (and nice holiydays)

> Carsten.

Christian


[Index of Archives]     [Linux Media]     [Asterisk]     [DCCP]     [Netdev]     [Xorg]     [Util Linux NG]     [Xfree86]     [Big List of Linux Books]     [Fedora Users]     [Fedora Women]     [ALSA Devel]     [Linux USB]

  Powered by Linux