]> git.saurik.com Git - apt.git/commitdiff
Merged from debian-sid branch.
authorEugene V. Lyubimkin <jackyf@1501-debian>
Fri, 19 Dec 2008 19:49:54 +0000 (21:49 +0200)
committerEugene V. Lyubimkin <jackyf@1501-debian>
Fri, 19 Dec 2008 19:49:54 +0000 (21:49 +0200)
configure.in
debian/NEWS [new file with mode: 0644]
debian/NEWS.Debian [deleted file]
debian/changelog
doc/apt.conf.5.xml
methods/ftp.cc
methods/http.cc
methods/https.cc

index f90a32c3be31b7d8f75d507efde2f6352076ef9e..04d8a4712894adb86fa6bc23e9425695cad49af2 100644 (file)
@@ -18,7 +18,7 @@ AC_CONFIG_AUX_DIR(buildlib)
 AC_CONFIG_HEADER(include/config.h:buildlib/config.h.in include/apti18n.h:buildlib/apti18n.h.in)
 
 dnl -- SET THIS TO THE RELEASE VERSION --
-AC_DEFINE_UNQUOTED(VERSION,"0.7.20~exp3")
+AC_DEFINE_UNQUOTED(VERSION,"0.7.20")
 PACKAGE="apt"
 AC_DEFINE_UNQUOTED(PACKAGE,"$PACKAGE")
 AC_SUBST(PACKAGE)
diff --git a/debian/NEWS b/debian/NEWS
new file mode 100644 (file)
index 0000000..5730fd7
--- /dev/null
@@ -0,0 +1,27 @@
+apt (0.7.20) unstable; urgency=low
+
+  * Code that determines which proxy to use was changed. Now
+    'Acquire::{http,ftp}::Proxy[::<host>]' options have the highest priority,
+    and '{http,ftp}_proxy' environment variables are used only if options
+    mentioned above are not specified.
+
+ -- Eugene V. Lyubimkin <jackyf.devel@gmail.com>  Thu, 18 Dec 2008 00:30:16 +0200
+
+apt (0.6.44) unstable; urgency=low
+
+  * apt-ftparchive --db now uses Berkeley DB_BTREE instead of DB_HASH. 
+    If you use a database created by an older version of apt, delete 
+    it and allow it to be recreated the next time.
+
+ -- Michael Vogt <mvo@debian.org>  Wed, 26 Apr 2006 12:57:53 +0200
+
+apt (0.5.25) unstable; urgency=low
+
+  * apt-ftparchive --db now uses Berkeley DB version 4.2.  If used with a
+    database created by an older version of apt, an attempt will be made
+    to upgrade the database, but this may not work in all cases.  If your
+    database is not automatically upgraded, delete it and allow it to be
+    recreated the next time.
+
+ -- Matt Zimmerman <mdz@debian.org>  Sat,  8 May 2004 12:38:07 -0700
+
diff --git a/debian/NEWS.Debian b/debian/NEWS.Debian
deleted file mode 100644 (file)
index f44d196..0000000
+++ /dev/null
@@ -1,18 +0,0 @@
-apt (0.6.44) unstable; urgency=low
-
-  * apt-ftparchive --db now uses Berkeley DB_BTREE instead of DB_HASH. 
-    If you use a database created by an older version of apt, delete 
-    it and allow it to be recreated the next time.
-
- -- Michael Vogt <mvo@debian.org>  Wed, 26 Apr 2006 12:57:53 +0200
-
-apt (0.5.25) unstable; urgency=low
-
-  * apt-ftparchive --db now uses Berkeley DB version 4.2.  If used with a
-    database created by an older version of apt, an attempt will be made
-    to upgrade the database, but this may not work in all cases.  If your
-    database is not automatically upgraded, delete it and allow it to be
-    recreated the next time.
-
- -- Matt Zimmerman <mdz@debian.org>  Sat,  8 May 2004 12:38:07 -0700
-
index d0174400ce57d18c6de78d3f94aac39b69149932..0adbbac1b2a9914b94824e1f30a36f3104f5fadb 100644 (file)
@@ -7,12 +7,18 @@ apt (0.7.20) unstable; urgency=low
   * buildlib/config.{sub,guess}:
     - Renewed. This fixes lintian errors.
   * doc/apt.conf.5.xml, debian/apt-transport-https:
-    - Documented briefly 'APT::https' group of options. (Closes: #507398)
+    - Documented briefly 'Acquire::https' group of options. (Closes: #507398)
     - Applied patch from Daniel Burrows to document 'Debug' group of options.
       (Closes: #457265)
     - Mentioned 'APT::Periodic' and 'APT::Archives' groups of options.
       (Closes: #438559)
     - Mentioned '/* ... */' comments. (Closes: #507601)
+  * methods/{http,https,ftp}, doc/apt.conf.5.xml:
+    - Changed and unified the code that determines which proxy to use. Now
+      'Acquire::{http,ftp}::Proxy[::<host>]' options have the highest priority,
+      and '{http,ftp}_proxy' environment variables are used only if options
+      mentioned above are not specified.
+      (Closes: #445985, #157759, #320184, #365880, #479617)
 
   [ Michael Vogt ]
   * add option to "apt-get build-dep" to mark the needed 
@@ -29,7 +35,7 @@ apt (0.7.20) unstable; urgency=low
     - Finnish updated. Closes: #508449 
     - Galician updated. Closes: #509151
 
- -- Eugene V. Lyubimkin <jackyf.devel@gmail.com>  Sat, 06 Dec 2008 20:57:00 +0200
+ -- Eugene V. Lyubimkin <jackyf.devel@gmail.com>  Mon, 15 Dec 2008 23:48:46 +0200
 
 apt (0.7.20~exp2) unstable; urgency=low
 
index 74966c5b3738594d0da2b69c4e4c73bdea13a398..4d9e708a875d0e33b160097e398e0f3d90fed2f6 100644 (file)
@@ -202,8 +202,9 @@ DPkg::Pre-Install-Pkgs {"/usr/sbin/dpkg-preconfigure --apt";};
      standard form of <literal>http://[[user][:pass]@]host[:port]/</literal>. Per 
      host proxies can also be specified by using the form 
      <literal>http::Proxy::&lt;host&gt;</literal> with the special keyword <literal>DIRECT</literal> 
-     meaning to use no proxies. The <envar>http_proxy</envar> environment variable
-     will override all settings.</para>
+        meaning to use no proxies. If no one of the above settings is specified,
+        <envar>http_proxy</envar> environment variable
+        will be used.</para>
 
      <para>Three settings are provided for cache control with HTTP/1.1 compliant 
      proxy caches. <literal>No-Cache</literal> tells the proxy to not use its cached 
@@ -251,9 +252,13 @@ DPkg::Pre-Install-Pkgs {"/usr/sbin/dpkg-preconfigure --apt";};
         </para></listitem></varlistentry>
 
      <varlistentry><term>ftp</term>
-     <listitem><para>FTP URIs; ftp::Proxy is the default proxy server to use. It is in the 
-     standard form of <literal>ftp://[[user][:pass]@]host[:port]/</literal> and is 
-     overridden by the <envar>ftp_proxy</envar> environment variable. To use a ftp 
+     <listitem><para>FTP URIs; ftp::Proxy is the default ftp proxy to use. It is in the 
+     standard form of <literal>ftp://[[user][:pass]@]host[:port]/</literal>. Per 
+     host proxies can also be specified by using the form 
+     <literal>ftp::Proxy::&lt;host&gt;</literal> with the special keyword <literal>DIRECT</literal> 
+        meaning to use no proxies. If no one of the above settings is specified,
+        <envar>ftp_proxy</envar> environment variable
+        will be used. To use a ftp 
      proxy you will have to set the <literal>ftp::ProxyLogin</literal> script in the 
      configuration file. This entry specifies the commands to send to tell 
      the proxy server what to connect to. Please see 
index 554a24cf52c52c19a7ca11a23477a61b934d7bc3..c91600ad5388f7cc675922ce731e37ad43faf59e 100644 (file)
@@ -112,23 +112,28 @@ bool FTPConn::Open(pkgAcqMethod *Owner)
    Close();
    
    // Determine the proxy setting
-   if (getenv("ftp_proxy") == 0)
+   string SpecificProxy = _config->Find("Acquire::ftp::Proxy::" + ServerName.Host);
+   if (!SpecificProxy.empty())
    {
-      string DefProxy = _config->Find("Acquire::ftp::Proxy");
-      string SpecificProxy = _config->Find("Acquire::ftp::Proxy::" + ServerName.Host);
-      if (SpecificProxy.empty() == false)
-      {
-        if (SpecificProxy == "DIRECT")
-           Proxy = "";
-        else
-           Proxy = SpecificProxy;
-      }   
-      else
-        Proxy = DefProxy;
+          if (SpecificProxy == "DIRECT")
+                  Proxy = "";
+          else
+                  Proxy = SpecificProxy;
    }
    else
-      Proxy = getenv("ftp_proxy");
-   
+   {
+          string DefProxy = _config->Find("Acquire::ftp::Proxy");
+          if (!DefProxy.empty())
+          {
+                  Proxy = DefProxy;
+          }
+          else
+          {
+                  char* result = getenv("ftp_proxy");
+                  Proxy = result ? result : "";
+          }
+   }
+
    // Parse no_proxy, a , separated list of domains
    if (getenv("no_proxy") != 0)
    {
index b3c791fa0a0e2fd555e81b4361dd7076b08e88bf..5d18b3adca3e2b586a6f366f5f598175da8df851 100644 (file)
@@ -309,22 +309,27 @@ bool ServerState::Open()
    Persistent = true;
    
    // Determine the proxy setting
-   if (getenv("http_proxy") == 0)
+   string SpecificProxy = _config->Find("Acquire::http::Proxy::" + ServerName.Host);
+   if (!SpecificProxy.empty())
    {
-      string DefProxy = _config->Find("Acquire::http::Proxy");
-      string SpecificProxy = _config->Find("Acquire::http::Proxy::" + ServerName.Host);
-      if (SpecificProxy.empty() == false)
-      {
-        if (SpecificProxy == "DIRECT")
-           Proxy = "";
-        else
-           Proxy = SpecificProxy;
-      }   
-      else
-        Proxy = DefProxy;
+          if (SpecificProxy == "DIRECT")
+                  Proxy = "";
+          else
+                  Proxy = SpecificProxy;
    }
    else
-      Proxy = getenv("http_proxy");
+   {
+          string DefProxy = _config->Find("Acquire::http::Proxy");
+          if (!DefProxy.empty())
+          {
+                  Proxy = DefProxy;
+          }
+          else
+          {
+                  char* result = getenv("http_proxy");
+                  Proxy = result ? result : "";
+          }
+   }
    
    // Parse no_proxy, a , separated list of domains
    if (getenv("no_proxy") != 0)
index 98dfeefa10ad638673580f07e985828d9094b11c..728869fa255797d54a650f9b7c9e09be53956910 100644 (file)
@@ -61,19 +61,26 @@ void HttpsMethod::SetupProxy()
    URI ServerName = Queue->Uri;
 
    // Determine the proxy setting
-   if (getenv("http_proxy") == 0)
+   string SpecificProxy = _config->Find("Acquire::http::Proxy::" + ServerName.Host);
+   if (!SpecificProxy.empty())
    {
-      string DefProxy = _config->Find("Acquire::http::Proxy");
-      string SpecificProxy = _config->Find("Acquire::http::Proxy::" + ServerName.Host);
-      if (SpecificProxy.empty() == false)
-      {
-        if (SpecificProxy == "DIRECT")
-           Proxy = "";
-        else
-           Proxy = SpecificProxy;
-      }   
-      else
-        Proxy = DefProxy;
+          if (SpecificProxy == "DIRECT")
+                  Proxy = "";
+          else
+                  Proxy = SpecificProxy;
+   }
+   else
+   {
+          string DefProxy = _config->Find("Acquire::http::Proxy");
+          if (!DefProxy.empty())
+          {
+                  Proxy = DefProxy;
+          }
+          else
+          {
+                  char* result = getenv("http_proxy");
+                  Proxy = result ? result : "";
+          }
    }
    
    // Parse no_proxy, a , separated list of domains