summaryrefslogtreecommitdiff
path: root/libavformat/http.c
diff options
context:
space:
mode:
authorMartin Storsjö <martin@martin.st>2011-04-20 11:40:29 +0200
committerMartin Storsjö <martin@martin.st>2011-04-20 14:59:45 +0300
commitc60112f26873afafb55d24cc50a0e93ad9411373 (patch)
tree62d01be1c17198fe7593818536d1138821fc7ffd /libavformat/http.c
parent8408e1d7d69aad57e633c27a6bcd522a15fa3702 (diff)
libavformat: Make protocols pass URLContext as log context where available
Since the libavformat major bump, URLContext contains an AVClass, making it a usable log context. Signed-off-by: Martin Storsjö <martin@martin.st>
Diffstat (limited to 'libavformat/http.c')
-rw-r--r--libavformat/http.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/libavformat/http.c b/libavformat/http.c
index 190f844ea1..7d59152409 100644
--- a/libavformat/http.c
+++ b/libavformat/http.c
@@ -70,7 +70,7 @@ void ff_http_set_headers(URLContext *h, const char *headers)
int len = strlen(headers);
if (len && strcmp("\r\n", headers + len - 2))
- av_log(NULL, AV_LOG_ERROR, "No trailing CRLF found in HTTP header.\n");
+ av_log(h, AV_LOG_ERROR, "No trailing CRLF found in HTTP header.\n");
av_strlcpy(s->headers, headers, sizeof(s->headers));
}
@@ -232,7 +232,7 @@ static int process_line(URLContext *h, char *line, int line_count,
* don't abort until all headers have been parsed. */
if (s->http_code >= 400 && s->http_code < 600 && s->http_code != 401) {
end += strspn(end, SPACE_CHARS);
- av_log(NULL, AV_LOG_WARNING, "HTTP error %d %s\n",
+ av_log(h, AV_LOG_WARNING, "HTTP error %d %s\n",
s->http_code, end);
return -1;
}