From f6237efdccd4b176efddaede6c9d90b8cecc0aa3 Mon Sep 17 00:00:00 2001 From: Michael Vogt Date: Thu, 23 Dec 2004 12:08:47 +0000 Subject: [PATCH] * removed Release.gpg files in partial/ before fetching a new one --- apt-pkg/acquire-item.cc | 13 ++++--------- debian/changelog | 4 ++-- po/apt-all.pot | 12 ++++++------ 3 files changed, 12 insertions(+), 17 deletions(-) diff --git a/apt-pkg/acquire-item.cc b/apt-pkg/acquire-item.cc index d1bed417..d96ea1ff 100644 --- a/apt-pkg/acquire-item.cc +++ b/apt-pkg/acquire-item.cc @@ -321,6 +321,10 @@ pkgAcqMetaSig::pkgAcqMetaSig(pkgAcquire *Owner, DestFile = _config->FindDir("Dir::State::lists") + "partial/"; DestFile += URItoFileName(URI); + // remove any partial downloaded sig-file. it may confuse proxies + // and is too small to warrant a partial download anyway + unlink(DestFile.c_str()); + // Create the item Desc.Description = URIDesc; Desc.Owner = this; @@ -393,15 +397,6 @@ void pkgAcqMetaSig::Failed(string Message,pkgAcquire::MethodConfig *Cnf) string Final = _config->FindDir("Dir::State::lists") + URItoFileName(RealURI); unlink(Final.c_str()); - // if we debug leave the sig-file in partial/ to see what went wrong - // else delete it - if (!_config->FindB("Debug::pkgAcquire::Auth", false)) { - - Final = _config->FindDir("Dir::State::lists") + "partial/"+ URItoFileName(RealURI); - unlink(Final.c_str()); - } - - // queue a pkgAcqMetaIndex with no sigfile new pkgAcqMetaIndex(Owner, MetaIndexURI, MetaIndexURIDesc, MetaIndexShortDesc, "", IndexTargets, MetaIndexParser); diff --git a/debian/changelog b/debian/changelog index 7825c85a..421914b3 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,7 +1,7 @@ apt (0.6.27ubuntu4) hoary; urgency=low - * if a sign-file download fails, delete the the partial downloaded - file in "partial/" + * remove old sig-file in partial/ before starting to fetch a new sig-file + (see ubuntu #4769 for the rational) * added apt-key update method (uses ubuntu-keyring) * documented the "--allow-unauthenticated" switch * added DEB_BUILD_PROG_OPTS to debian/rules (additonal options can be diff --git a/po/apt-all.pot b/po/apt-all.pot index 8b0b9eb7..dfafb2c4 100644 --- a/po/apt-all.pot +++ b/po/apt-all.pot @@ -7,7 +7,7 @@ msgid "" msgstr "" "Project-Id-Version: PACKAGE VERSION\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2004-12-23 11:46+0100\n" +"POT-Creation-Date: 2004-12-23 12:36+0100\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" @@ -2259,31 +2259,31 @@ msgstr "" msgid "rename failed, %s (%s -> %s)." msgstr "" -#: apt-pkg/acquire-item.cc:235 apt-pkg/acquire-item.cc:904 +#: apt-pkg/acquire-item.cc:235 apt-pkg/acquire-item.cc:897 msgid "MD5Sum mismatch" msgstr "" -#: apt-pkg/acquire-item.cc:718 +#: apt-pkg/acquire-item.cc:711 #, c-format msgid "" "I wasn't able to locate a file for the %s package. This might mean you need " "to manually fix this package. (due to missing arch)" msgstr "" -#: apt-pkg/acquire-item.cc:771 +#: apt-pkg/acquire-item.cc:764 #, c-format msgid "" "I wasn't able to locate file for the %s package. This might mean you need to " "manually fix this package." msgstr "" -#: apt-pkg/acquire-item.cc:807 +#: apt-pkg/acquire-item.cc:800 #, c-format msgid "" "The package index files are corrupted. No Filename: field for package %s." msgstr "" -#: apt-pkg/acquire-item.cc:894 +#: apt-pkg/acquire-item.cc:887 msgid "Size mismatch" msgstr "" -- 2.20.1