diff options
author | Michael Vogt <mvo@debian.org> | 2014-01-16 08:03:24 +0100 |
---|---|---|
committer | Michael Vogt <mvo@debian.org> | 2014-01-16 08:03:24 +0100 |
commit | db6594dfc508378b6d658aff2761da5406404238 (patch) | |
tree | 4a92c9e418c7d6dd8a53f5670b1f02be3d19b2d3 | |
parent | 181d587044121448e4d9925cc18ffb404b7b4a9c (diff) |
remove "," in components again
-rw-r--r-- | apt-pkg/sourcelist.cc | 6 | ||||
-rwxr-xr-x | test/integration/test-apt-sources-deb822 | 11 |
2 files changed, 1 insertions, 16 deletions
diff --git a/apt-pkg/sourcelist.cc b/apt-pkg/sourcelist.cc index 5e4a58e95..42ada7e18 100644 --- a/apt-pkg/sourcelist.cc +++ b/apt-pkg/sourcelist.cc @@ -363,11 +363,7 @@ int pkgSourceList::ParseFileDeb822(string File) // now create one item per section string const Section = Tags.FindS("Section"); - std::vector<std::string> list; - if (Section.find(",")) - list = StringSplit(Section, ","); - else - list = StringSplit(Section, " "); + std::vector<std::string> list = StringSplit(Section, " "); for (std::vector<std::string>::const_iterator I = list.begin(); I != list.end(); I++) Parse->CreateItem(SrcList, URI, Dist, (*I), Options); diff --git a/test/integration/test-apt-sources-deb822 b/test/integration/test-apt-sources-deb822 index bacad1ed4..b110c1462 100755 --- a/test/integration/test-apt-sources-deb822 +++ b/test/integration/test-apt-sources-deb822 @@ -33,17 +33,6 @@ testequalwithmsg "Simple deb822 sources.list works" "'http://ftp.debian.org/debi 'http://ftp.debian.org/debian/dists/stable/main/i18n/Translation-en.bz2' ftp.debian.org_debian_dists_stable_main_i18n_Translation-en 0 : 'http://ftp.debian.org/debian/dists/stable/InRelease' ftp.debian.org_debian_dists_stable_InRelease 0 " aptget update --print-uris - -# two sections (we support both "," and " " as seperator) -echo "$BASE" | sed s/main/"main,contrib"/ > $SOURCES - -testequalwithmsg "Two sections deb822 sources.list work" "'http://ftp.debian.org/debian/dists/stable/main/binary-i386/Packages.bz2' ftp.debian.org_debian_dists_stable_main_binary-i386_Packages 0 : -'http://ftp.debian.org/debian/dists/stable/contrib/binary-i386/Packages.bz2' ftp.debian.org_debian_dists_stable_contrib_binary-i386_Packages 0 : -'http://ftp.debian.org/debian/dists/stable/contrib/i18n/Translation-en.bz2' ftp.debian.org_debian_dists_stable_contrib_i18n_Translation-en 0 : -'http://ftp.debian.org/debian/dists/stable/main/i18n/Translation-en.bz2' ftp.debian.org_debian_dists_stable_main_i18n_Translation-en 0 : -'http://ftp.debian.org/debian/dists/stable/InRelease' ftp.debian.org_debian_dists_stable_InRelease 0 " aptget update --print-uris - - # Two entries echo "$BASE" > $SOURCES echo "" >> $SOURCES |