[FFmpeg-devel] [PATCH] RTP: use dprintf(), allow compilation with -DDEBUG

Michael Niedermayer michaelni
Sun Jul 13 21:34:27 CEST 2008


On Sun, Jul 13, 2008 at 07:26:53PM +0100, Mans Rullgard wrote:
> ---
>  libavformat/rtpdec.c |    8 ++------
>  libavformat/rtpenc.c |   12 +++---------
>  2 files changed, 5 insertions(+), 15 deletions(-)
> 
> diff --git a/libavformat/rtpdec.c b/libavformat/rtpdec.c
> index 608612b..1a43bba 100644
> --- a/libavformat/rtpdec.c
> +++ b/libavformat/rtpdec.c
> @@ -250,13 +250,9 @@ int rtp_check_and_send_back_rr(RTPDemuxContext *s, int count)
>      len = url_close_dyn_buf(pb, &buf);
>      if ((len > 0) && buf) {
>          int result;
> -#if defined(DEBUG)
> -        printf("sending %d bytes of RR\n", len);
> -#endif
> +        dprintf(NULL, "sending %d bytes of RR\n", len);
>          result= url_write(s->rtp_ctx, buf, len);
> -#if defined(DEBUG)
> -        printf("result from url_write: %d\n", result);
> -#endif
> +        dprintf(NULL, "result from url_write: %d\n", result);
>          av_free(buf);

These could use s->ic as context instead of NULL

[...]
-- 
Michael     GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

Asymptotically faster algorithms should always be preferred if you have
asymptotical amounts of data
-------------- 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/20080713/c3133a73/attachment.pgp>



More information about the ffmpeg-devel mailing list