diff mbox

[FFmpeg-devel,v2,2/5] avformat/http: add "Opening" info logging to ff_http_do_new_request

Message ID 20171213003511.25342-3-ffmpeg@tmm1.net
State Accepted
Commit 9395e44b8d20d1d4c72dd5b42d28721ca191d957
Headers show

Commit Message

Aman Gupta Dec. 13, 2017, 12:35 a.m. UTC
From: Aman Gupta <aman@tmm1.net>

This mimics logging that was added in 53e0d5d7247 for security
purposes.
---
 libavformat/http.c | 1 +
 1 file changed, 1 insertion(+)

Comments

Michael Niedermayer Dec. 15, 2017, 7:34 p.m. UTC | #1
On Tue, Dec 12, 2017 at 04:35:08PM -0800, Aman Gupta wrote:
> From: Aman Gupta <aman@tmm1.net>
> 
> This mimics logging that was added in 53e0d5d7247 for security
> purposes.
> ---
>  libavformat/http.c | 1 +
>  1 file changed, 1 insertion(+)

iam not sure this does not cause too much noise with image sequences
image%d.jpg for example

but LGTM if that is not an issue or noone minds

thanks

[...]
Aman Gupta Dec. 15, 2017, 7:38 p.m. UTC | #2
On Fri, Dec 15, 2017 at 11:34 AM Michael Niedermayer <michael@niedermayer.cc>
wrote:

> On Tue, Dec 12, 2017 at 04:35:08PM -0800, Aman Gupta wrote:
> > From: Aman Gupta <aman@tmm1.net>
> >
> > This mimics logging that was added in 53e0d5d7247 for security
> > purposes.
> > ---
> >  libavformat/http.c | 1 +
> >  1 file changed, 1 insertion(+)
>
> iam not sure this does not cause too much noise with image sequences
> image%d.jpg for example
>
> but LGTM if that is not an issue or noone minds


Not a problem as this only affects ff_http_do_new_request, which is used
just from hls and rtmp muxers.


>
> thanks
>
> [...]
>
> --
> Michael     GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB
>
> Elect your leaders based on what they did after the last election, not
> based on what they say before an election.
>
> _______________________________________________
> ffmpeg-devel mailing list
> ffmpeg-devel@ffmpeg.org
> http://ffmpeg.org/mailman/listinfo/ffmpeg-devel
>
diff mbox

Patch

diff --git a/libavformat/http.c b/libavformat/http.c
index a3c36423fc..ffdf11cf7e 100644
--- a/libavformat/http.c
+++ b/libavformat/http.c
@@ -336,6 +336,7 @@  int ff_http_do_new_request(URLContext *h, const char *uri)
     if (!s->location)
         return AVERROR(ENOMEM);
 
+    av_log(s, AV_LOG_INFO, "Opening \'%s\' for %s\n", uri, h->flags & AVIO_FLAG_WRITE ? "writing" : "reading");
     ret = http_open_cnx(h, &options);
     av_dict_free(&options);
     return ret;