diff options
author | Daniel Caujolle-Bert <f1rmb@users.sourceforge.net> | 2003-11-26 19:43:26 +0000 |
---|---|---|
committer | Daniel Caujolle-Bert <f1rmb@users.sourceforge.net> | 2003-11-26 19:43:26 +0000 |
commit | 3050d97eb83cfdfb4d04a51231acba47e6addf1c (patch) | |
tree | 4337d69086ce7d870214e7e5f6a028f8b417521e /src/input/input_http.c | |
parent | ae2a2a8e08ab3140d5c7ee3a5f33e7db81f76b09 (diff) | |
download | xine-lib-3050d97eb83cfdfb4d04a51231acba47e6addf1c.tar.gz xine-lib-3050d97eb83cfdfb4d04a51231acba47e6addf1c.tar.bz2 |
lprintf cleanup, pass I.
CVS patchset: 5796
CVS date: 2003/11/26 19:43:26
Diffstat (limited to 'src/input/input_http.c')
-rw-r--r-- | src/input/input_http.c | 34 |
1 files changed, 18 insertions, 16 deletions
diff --git a/src/input/input_http.c b/src/input/input_http.c index e1a7bb9fa..95ee7422b 100644 --- a/src/input/input_http.c +++ b/src/input/input_http.c @@ -19,7 +19,7 @@ * * input plugin for http network streams * - * $Id: input_http.c,v 1.75 2003/11/26 08:09:58 tmattern Exp $ + * $Id: input_http.c,v 1.76 2003/11/26 19:43:31 f1rmb Exp $ */ #ifdef HAVE_CONFIG_H @@ -42,16 +42,18 @@ #include <sys/time.h> +#define LOG_MODULE "input_http" +#define LOG_VERBOSE +/* +#define LOG +*/ + #include "xine_internal.h" #include "xineutils.h" #include "input_plugin.h" #include "net_buf_ctrl.h" #include "http_helper.h" -/* -#define LOG -*/ - #define BUFSIZE 1024 #define DEFAULT_HTTP_PORT 80 @@ -216,14 +218,14 @@ static void http_plugin_read_metainf (input_plugin_t *this_gen) { /* get the length of the metadata */ this_gen->read(this_gen, &len, 1); - lprintf ("input_http: http_plugin_read_metainf: len=%d\n", len); + lprintf ("http_plugin_read_metainf: len=%d\n", len); if (len > 0) { this_gen->read(this_gen, metadata_buf, len * 16); metadata_buf[len * 16] = '\0'; - lprintf ("input_http: http_plugin_read_metainf: %s\n", metadata_buf); + lprintf ("http_plugin_read_metainf: %s\n", metadata_buf); /* Extract the title of the current song */ if ((songtitle = strstr(metadata_buf, "StreamTitle='"))) { @@ -235,7 +237,7 @@ static void http_plugin_read_metainf (input_plugin_t *this_gen) { (strcmp(songtitle, this->shoutcast_songtitle))) && (strlen(songtitle) > 0)) { - lprintf ("input_http: http_plugin_read_metainf: songtitle: %s\n", songtitle); + lprintf ("http_plugin_read_metainf: songtitle: %s\n", songtitle); if (this->shoutcast_songtitle) free(this->shoutcast_songtitle); @@ -288,7 +290,7 @@ static off_t http_plugin_read (input_plugin_t *this_gen, if (n > (nlen - num_bytes)) n = nlen - num_bytes; - lprintf ("input_http: %lld bytes from preview (which has %lld bytes)\n", n, this->preview_size); + lprintf ("%lld bytes from preview (which has %lld bytes)\n", n, this->preview_size); if (this->shoutcast_mode) { if ((this->shoutcast_pos + n) >= this->shoutcast_metaint) { @@ -376,7 +378,7 @@ static int read_shoutcast_header(http_input_plugin_t *this) { linenum++; - lprintf ("input_http: shoutcast answer: >%s<\n", this->buf); + lprintf ("shoutcast answer: >%s<\n", this->buf); if (!strncasecmp(this->buf, "icy-name:", 9)) { _x_meta_info_set(this->stream, XINE_META_INFO_ALBUM, @@ -398,7 +400,7 @@ static int read_shoutcast_header(http_input_plugin_t *this) { /* metadata interval (in byte) */ if (sscanf(this->buf, "icy-metaint:%d", &this->shoutcast_metaint) == 1) { - lprintf("input_http: shoutcast_metaint: %d\n", this->shoutcast_metaint); + lprintf("shoutcast_metaint: %d\n", this->shoutcast_metaint); } if (len == -1) @@ -409,7 +411,7 @@ static int read_shoutcast_header(http_input_plugin_t *this) { len ++; } - lprintf ("input_http: end of the shoutcast header\n"); + lprintf ("end of the shoutcast header\n"); return 0; } @@ -680,7 +682,7 @@ static int http_plugin_open (input_plugin_t *this_gen ) { return 0; } - lprintf ("input_http: request sent: >%s<\n", this->buf); + lprintf ("request sent: >%s<\n", this->buf); /* read and parse reply */ done = 0; len = 0; linenum = 0; @@ -708,7 +710,7 @@ static int http_plugin_open (input_plugin_t *this_gen ) { linenum++; - lprintf ("input_http: answer: >%s<\n", this->buf); + lprintf ("answer: >%s<\n", this->buf); if (linenum == 1) { int httpver, httpsub; @@ -755,7 +757,7 @@ static int http_plugin_open (input_plugin_t *this_gen ) { if (!strncasecmp(this->buf, "Location: ", 10)) { char *href = (this->buf + 10); - lprintf ("input_http: trying to open target of redirection: >%s<\n", href); + lprintf ("trying to open target of redirection: >%s<\n", href); free(this->mrl); this->mrl = strdup(href); @@ -771,7 +773,7 @@ static int http_plugin_open (input_plugin_t *this_gen ) { len ++; } - lprintf ("input_http: end of headers\n"); + lprintf ("end of headers\n"); /* * fill preview buffer |