Mailing List archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[vdr] Re: VDR developer version 1.3.0
Klaus Schmidinger wrote:
>
> Robert Schiele wrote:
> >
> > On Mon, Jan 05, 2004 at 12:51:10AM +0200, Lauri Tischler wrote:
> > > Nice patch, cleans up all cruft, just one warning remains
> > >
> > > g++ -O2 -g -Wall -Woverloaded-virtual -c si.c
> > > si.c: In member function `void SI::String::decodeText(char*)':
> > > si.c:222: warning: comparison is always true due to limited range of data
> > > type
> >
> > You can fix this by doing the following:
> > ...
> Hmmm, I wonder why the check against 0xFF was introduced in the first place?
> It wasn't there in the original 'libdvt' code written by Rolf Hakenes,
> and I'd say it isn't necessary, anyway, since 'char' is assumed to be 8 bit.
>
> I guess I'll just remove the (*from <= 0xFF) check.
Well, a further look into the original 'libdtv' code showed that
it had checked for
if ((*Buffer >= ' ' && *Buffer <= '~') || (*Buffer == '\n') ||
(*Buffer >= 0xa0))
while the new 'libsi' code checks
if ( ((' ' <= *from) && (*from <= '~'))
|| (*from == '\n')
|| ((0xA0 <= *from) && (*from <= 0xFF))
I believe the last line here should read
|| (*from >= 0xA0)
or am I missing something here?
Klaus
--
Info:
To unsubscribe send a mail to ecartis@linuxtv.org with "unsubscribe vdr" as subject.
Home |
Main Index |
Thread Index