X-Git-Url: https://git.saurik.com/apt.git/blobdiff_plain/5dd4c8b811d9c7bc33e50254811f5bc0fc37f872..ff72bd0dc7bd4d3bb6979e70d7bca9a07d28af28:/apt-pkg/deb/debmetaindex.cc?ds=sidebyside

diff --git a/apt-pkg/deb/debmetaindex.cc b/apt-pkg/deb/debmetaindex.cc
index eb01a0156..717d0bcde 100644
--- a/apt-pkg/deb/debmetaindex.cc
+++ b/apt-pkg/deb/debmetaindex.cc
@@ -23,7 +23,7 @@ string debReleaseIndex::Info(const char *Type, string const &Section, string con
    else
    {
       Info += Dist + '/' + Section;
-      if (Arch.empty() == true)
+      if (Arch.empty() != true)
 	 Info += " " + Arch;
    }
    Info += " ";
@@ -214,6 +214,7 @@ bool debReleaseIndex::GetIndexes(pkgAcquire *Owner, bool const &GetAll) const
 	     s != sections.end(); ++s)
 		for (set<string>::const_iterator l = s->second.begin();
 		     l != s->second.end(); l++) {
+			if (*l == "none") continue;
 			debTranslationsIndex i = debTranslationsIndex(URI,Dist,s->first,(*l).c_str());
 			i.GetIndexes(Owner);
 		}
@@ -268,8 +269,10 @@ vector <pkgIndexFile *> *debReleaseIndex::GetIndexFiles() {
 	for (map<string, set<string> >::const_iterator s = sections.begin();
 	     s != sections.end(); ++s)
 		for (set<string>::const_iterator l = s->second.begin();
-		     l != s->second.end(); l++)
+		     l != s->second.end(); l++) {
+			if (*l == "none") continue;
 			Indexes->push_back(new debTranslationsIndex(URI,Dist,s->first,(*l).c_str()));
+		}
 
 	return Indexes;
 }
@@ -310,7 +313,7 @@ class debSLTypeDebian : public pkgSourceList::Type
    {
       map<string, string>::const_iterator const arch = Options.find("arch");
       vector<string> const Archs =
-		(arch != Options.end()) ? ExplodeString(arch->second) :
+		(arch != Options.end()) ? VectorizeString(arch->second, ',') :
 				APT::Configuration::getArchitectures();
 
       for (vector<metaIndex *>::const_iterator I = List.begin();
@@ -329,7 +332,12 @@ class debSLTypeDebian : public pkgSourceList::Type
 	    if (IsSrc == true)
 	       Deb->PushSectionEntry("source", new debReleaseIndex::debSectionEntry(Section, IsSrc));
 	    else
-	       Deb->PushSectionEntry(Archs, new debReleaseIndex::debSectionEntry(Section, IsSrc));
+	    {
+	       if (Dist[Dist.size() - 1] == '/')
+		  Deb->PushSectionEntry("any", new debReleaseIndex::debSectionEntry(Section, IsSrc));
+	       else
+		  Deb->PushSectionEntry(Archs, new debReleaseIndex::debSectionEntry(Section, IsSrc));
+	    }
 	    return true;
 	 }
       }
@@ -339,7 +347,12 @@ class debSLTypeDebian : public pkgSourceList::Type
       if (IsSrc == true)
 	 Deb->PushSectionEntry ("source", new debReleaseIndex::debSectionEntry(Section, IsSrc));
       else
-	 Deb->PushSectionEntry (Archs, new debReleaseIndex::debSectionEntry(Section, IsSrc));
+      {
+	 if (Dist[Dist.size() - 1] == '/')
+	    Deb->PushSectionEntry ("any", new debReleaseIndex::debSectionEntry(Section, IsSrc));
+	 else
+	    Deb->PushSectionEntry (Archs, new debReleaseIndex::debSectionEntry(Section, IsSrc));
+      }
       List.push_back(Deb);
       return true;
    }