changeset 5009:822a36d7ac0a libavformat

Cosmetics : Use dprintf instead of printf. Patch by Peter Holik < $firstname @ $lastname . at >
author jai_menon
date Sat, 06 Jun 2009 17:32:59 +0000
parents 370160e040d9
children 1983ca659d54
files http.c
diffstat 1 files changed, 6 insertions(+), 8 deletions(-) [+]
line wrap: on
line diff
--- a/http.c	Sat Jun 06 16:46:40 2009 +0000
+++ b/http.c	Sat Jun 06 17:32:59 2009 +0000
@@ -29,8 +29,6 @@
 /* XXX: POST protocol is not completely implemented because ffmpeg uses
    only a subset of it. */
 
-//#define DEBUG
-
 /* used for protocol handling */
 #define BUFFER_SIZE 1024
 #define URL_SIZE    4096
@@ -192,9 +190,9 @@
         while (isspace(*p))
             p++;
         s->http_code = strtol(p, NULL, 10);
-#ifdef DEBUG
-        printf("http_code=%d\n", s->http_code);
-#endif
+
+        dprintf(NULL, "http_code=%d\n", s->http_code);
+
         /* error codes are 4xx and 5xx */
         if (s->http_code >= 400 && s->http_code < 600)
             return -1;
@@ -278,9 +276,9 @@
     for(;;) {
         if (http_get_line(s, line, sizeof(line)) < 0)
             return AVERROR(EIO);
-#ifdef DEBUG
-        printf("header='%s'\n", line);
-#endif
+
+        dprintf(NULL, "header='%s'\n", line);
+
         err = process_line(h, line, s->line_count, new_location);
         if (err < 0)
             return err;