[FFmpeg-devel] AVC: Test if not consumed bytes are all 0
Michael Niedermayer
michaelni
Sun Feb 15 16:17:56 CET 2009
On Sun, Feb 15, 2009 at 01:19:27PM +0000, Carl Eugen Hoyos wrote:
> Michael Niedermayer <michaelni <at> gmx.at> writes:
>
> > > - av_log(h->s.avctx, AV_LOG_ERROR, "AVC: Consumed only %d bytes
> instead of %d\n", consumed, nalsize);
> > > + int i, debug_level = AV_LOG_DEBUG;
> > > + for (i = consumed; i < nalsize; i++)
> > > + if (buf[buf_index+i]){
> > > + debug_level = AV_LOG_ERROR;
> > > + break;
> > > + }
> > > + av_log(h->s.avctx, debug_level, "AVC: Consumed only %d bytes
> instead of %d\n", consumed, nalsize);
> > > consumed= nalsize;
> > > }
> > >
> >
> > ok without the unneeded "break"
>
> Do you want me to keep "{" and "}"?
whichever way you prefer
[...]
--
Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB
Awnsering whenever a program halts or runs forever is
On a turing machine, in general impossible (turings halting problem).
On any real computer, always possible as a real computer has a finite number
of states N, and will either halt in less than N cycles or never halt.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: Digital signature
URL: <http://lists.mplayerhq.hu/pipermail/ffmpeg-devel/attachments/20090215/7cd52fa4/attachment.pgp>
More information about the ffmpeg-devel
mailing list