summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorArch Librarian <arch@canonical.com>2004-09-20 17:04:41 +0000
committerArch Librarian <arch@canonical.com>2004-09-20 17:04:41 +0000
commitd6689735f2f19c2f9b551096963c7daf72e0dbb2 (patch)
treebaff7cdfcb418cf3f5d331c5f22806f8a51bce94
parent9202409d47a751e49cf783dc41471daee3b5f214 (diff)
* Fix Packages::Extensions support in apt-ftparchive ge...
Author: mdz Date: 2004-01-04 00:20:59 GMT * Fix Packages::Extensions support in apt-ftparchive generate (Closes: #225453)
-rw-r--r--debian/changelog7
-rw-r--r--ftparchive/writer.cc20
-rw-r--r--po/apt-all.pot2
3 files changed, 21 insertions, 8 deletions
diff --git a/debian/changelog b/debian/changelog
index 50af6a1f9..c11a6f6ce 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,10 @@
+apt (0.5.19) unstable; urgency=low
+
+ * Fix Packages::Extensions support in apt-ftparchive generate
+ (Closes: #225453)
+
+ -- Matt Zimmerman <mdz@debian.org> Sat, 3 Jan 2004 16:20:31 -0800
+
apt (0.5.18) unstable; urgency=low
* New no_NO.po file from Tollef Fog Heen <tfheen@debian.org> to fix
diff --git a/ftparchive/writer.cc b/ftparchive/writer.cc
index 5264f4c1f..bc03492f4 100644
--- a/ftparchive/writer.cc
+++ b/ftparchive/writer.cc
@@ -1,6 +1,6 @@
// -*- mode: cpp; mode: fold -*-
// Description /*{{{*/
-// $Id: writer.cc,v 1.12 2004/01/02 21:55:09 mdz Exp $
+// $Id: writer.cc,v 1.13 2004/01/04 00:20:59 mdz Exp $
/* ######################################################################
Writer
@@ -289,6 +289,7 @@ PackagesWriter::PackagesWriter(string DB,string Overrides,string ExtOverrides) :
Db(DB),Stats(Db.Stats)
{
Output = stdout;
+ SetExts(".deb .udeb .foo .bar .baz");
AddPattern("*.deb");
DeLinkLimit = 0;
@@ -319,15 +320,20 @@ bool FTWScanner::SetExts(string Vals)
{
ClearPatterns();
string::size_type Start = 0;
- for(string::size_type space = Vals.find(' ');
- space != string::npos;
- space = Vals.find(' ', space))
+ while (Start <= Vals.length()-1)
{
- if (space > 0)
+ string::size_type Space = Vals.find(' ',Start);
+ string::size_type Length;
+ if (Space == string::npos)
{
- AddPattern(string("*") + string(Start, space-1));
- Start = space + 1;
+ Length = Vals.length()-Start;
}
+ else
+ {
+ Length = Space-Start;
+ }
+ AddPattern(string("*") + Vals.substr(Start, Length));
+ Start += Length + 1;
}
return true;
diff --git a/po/apt-all.pot b/po/apt-all.pot
index ab453fc27..047ce097d 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-01-02 11:31-0800\n"
+"POT-Creation-Date: 2004-01-02 13:54-0800\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n"