summaryrefslogtreecommitdiff
path: root/apt-pkg/acquire.cc
diff options
context:
space:
mode:
authorMichael Vogt <michael.vogt@ubuntu.com>2005-03-31 09:07:12 +0000
committerMichael Vogt <michael.vogt@ubuntu.com>2005-03-31 09:07:12 +0000
commit2c38625920fa67d52ade11fd7d28cdb5373dc31c (patch)
tree7b156366cb6826cc6d141aa373ef6fc0655f53ca /apt-pkg/acquire.cc
parent66de63dde68e2cb3a26201a28a0fc8060432acd3 (diff)
* merged the apt--main with the 2004 bwlimit tree
Patches applied: * michael.vogt@canonical.com--2004/apt--bwlimit--0--base-0 tag of apt@packages.debian.org/apt--main--0--patch-47 * michael.vogt@canonical.com--2004/apt--bwlimit--0--patch-1 * fist attempt for bwlimit * michael.vogt@canonical.com--2004/apt--bwlimit--0--patch-2 * add a nanosleep, making it less cpu intensive * michael.vogt@canonical.com--2004/apt--bwlimit--0--patch-3 * use SingleInstance when DlLimit is activated * michael.vogt@canonical.com--2004/apt--bwlimit--0--patch-4 * cleanups, no code changes
Diffstat (limited to 'apt-pkg/acquire.cc')
-rw-r--r--apt-pkg/acquire.cc4
1 files changed, 4 insertions, 0 deletions
diff --git a/apt-pkg/acquire.cc b/apt-pkg/acquire.cc
index 70dce4f54..212c8d52b 100644
--- a/apt-pkg/acquire.cc
+++ b/apt-pkg/acquire.cc
@@ -266,6 +266,10 @@ pkgAcquire::MethodConfig *pkgAcquire::GetConfig(string Access)
if (Work.Start() == false)
return 0;
+ /* if a method uses DownloadLimit, we switch to SingleInstance mode */
+ if(_config->FindI("Acquire::"+Access+"::DlLimit",0) > 0)
+ Conf->SingleInstance = true;
+
return Conf;
}
/*}}}*/