[vlc-commits] [Git][videolan/vlc][master] old http: do not query nonexistent variable

Rémi Denis-Courmont (@Courmisch) gitlab at videolan.org
Thu Oct 14 15:53:09 UTC 2021



Rémi Denis-Courmont pushed to branch master at VideoLAN / VLC


Commits:
f908d96a by Rémi Denis-Courmont at 2021-10-14T15:31:37+00:00
old http: do not query nonexistent variable

If http-proxy exists, it is already checked by the common core code.

- - - - -


1 changed file:

- modules/access/http.c


Changes:

=====================================
modules/access/http.c
=====================================
@@ -219,19 +219,11 @@ static int Open( vlc_object_t *p_this )
     p_sys->psz_referrer = var_InheritString( p_access, "http-referrer" );
 
     /* Check proxy */
-    psz = var_InheritString( p_access, "http-proxy" );
-    if( psz == NULL )
-    {
-        msg_Dbg(p_access, "querying proxy for %s", psz_url);
-        psz = vlc_getProxyUrl(psz_url);
-
-        if (psz != NULL)
-            msg_Dbg(p_access, "proxy: %s", psz);
-        else
-            msg_Dbg(p_access, "no proxy");
-    }
+    msg_Dbg(p_access, "querying proxy for %s", psz_url);
+    psz = vlc_getProxyUrl(psz_url);
     if( psz != NULL )
     {
+        msg_Dbg(p_access, "proxy: %s", psz);
         p_sys->b_proxy = true;
         vlc_UrlParse( &p_sys->proxy, psz );
         free( psz );
@@ -250,6 +242,8 @@ static int Open( vlc_object_t *p_this )
             p_sys->proxy.i_port = 80;
         }
     }
+    else
+        msg_Dbg(p_access, "no proxy");
 
     msg_Dbg( p_access, "http: server='%s' port=%d file='%s'",
              p_sys->url.psz_host, p_sys->url.i_port,



View it on GitLab: https://code.videolan.org/videolan/vlc/-/commit/f908d96ac12bcbe462e8e0e477fbb662021a4cf8

-- 
View it on GitLab: https://code.videolan.org/videolan/vlc/-/commit/f908d96ac12bcbe462e8e0e477fbb662021a4cf8
You're receiving this email because of your account on code.videolan.org.




More information about the vlc-commits mailing list