diff mbox

[FFmpeg-devel] lavf/avio: Also print the https warning for missing tls protocol

Message ID CAB0OVGpThNx6AJRU=4P1G893bXvAqzk9+4yrq8ybqkTz8vCQSA@mail.gmail.com
State Accepted
Headers show

Commit Message

Carl Eugen Hoyos Oct. 21, 2017, 11:15 p.m. UTC
Hi!

On redirection to https, FFmpeg only shows "protocol missing" without
a hint to what is missing.

Please comment, Carl Eugen

Comments

Michael Niedermayer Oct. 23, 2017, 9:30 a.m. UTC | #1
On Sun, Oct 22, 2017 at 01:15:27AM +0200, Carl Eugen Hoyos wrote:
> Hi!
> 
> On redirection to https, FFmpeg only shows "protocol missing" without
> a hint to what is missing.
> 
> Please comment, Carl Eugen

>  avio.c |    2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> e7b346c9ce0c4f07004caec31c40bb561becc6e5  0001-lavf-avio-Print-the-https-error-also-for-missing-tls.patch
> From 8c068d06fa425471590a8ee8765ef510476a180d Mon Sep 17 00:00:00 2001
> From: Carl Eugen Hoyos <ceffmpeg@gmail.com>
> Date: Sun, 22 Oct 2017 01:11:55 +0200
> Subject: [PATCH] lavf/avio: Print the https warning also for missing tls
>  protocol.

LGTM

thx

[...]
Carl Eugen Hoyos Oct. 23, 2017, 9:50 a.m. UTC | #2
2017-10-23 11:30 GMT+02:00 Michael Niedermayer <michael@niedermayer.cc>:
> On Sun, Oct 22, 2017 at 01:15:27AM +0200, Carl Eugen Hoyos wrote:
>> Hi!
>>
>> On redirection to https, FFmpeg only shows "protocol missing" without
>> a hint to what is missing.
>>
>> Please comment, Carl Eugen
>
>>  avio.c |    2 +-
>>  1 file changed, 1 insertion(+), 1 deletion(-)
>> e7b346c9ce0c4f07004caec31c40bb561becc6e5  0001-lavf-avio-Print-the-https-error-also-for-missing-tls.patch
>> From 8c068d06fa425471590a8ee8765ef510476a180d Mon Sep 17 00:00:00 2001
>> From: Carl Eugen Hoyos <ceffmpeg@gmail.com>
>> Date: Sun, 22 Oct 2017 01:11:55 +0200
>> Subject: [PATCH] lavf/avio: Print the https warning also for missing tls
>>  protocol.
>
> LGTM

Patch applied.

Thank you, Carl Eugen
diff mbox

Patch

From 8c068d06fa425471590a8ee8765ef510476a180d Mon Sep 17 00:00:00 2001
From: Carl Eugen Hoyos <ceffmpeg@gmail.com>
Date: Sun, 22 Oct 2017 01:11:55 +0200
Subject: [PATCH] lavf/avio: Print the https warning also for missing tls
 protocol.

---
 libavformat/avio.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/libavformat/avio.c b/libavformat/avio.c
index 4718753..4dc4683 100644
--- a/libavformat/avio.c
+++ b/libavformat/avio.c
@@ -297,7 +297,7 @@  int ffurl_alloc(URLContext **puc, const char *filename, int flags,
        return url_alloc_for_protocol(puc, p, filename, flags, int_cb);
 
     *puc = NULL;
-    if (av_strstart(filename, "https:", NULL))
+    if (av_strstart(filename, "https:", NULL) || av_strstart(filename, "tls:", NULL))
         av_log(NULL, AV_LOG_WARNING, "https protocol not found, recompile FFmpeg with "
                                      "openssl, gnutls "
                                      "or securetransport enabled.\n");
-- 
1.7.10.4