]> git.saurik.com Git - apt.git/blobdiff - ftparchive/writer.cc
fix 'Source' to 'Package' rename in apt-ftparchive
[apt.git] / ftparchive / writer.cc
index db68c21f05f97f8e6204856e3d98564254c90666..855e0ef792b39273082b32471966b7286fc2253c 100644 (file)
@@ -837,7 +837,8 @@ bool SourcesWriter::DoPackage(string FileName)
    // (5 hardcoded + checksums + maintainer + end marker)
    std::vector<TFRewriteData> Changes;
 
-   Changes.push_back(SetTFRewriteData("Source",Package.c_str(),"Package"));
+   Changes.push_back(SetTFRewriteData("Source", 0));
+   Changes.push_back(SetTFRewriteData("Package",Package.c_str()));
    if (Files.empty() == false)
       Changes.push_back(SetTFRewriteData("Files",Files.c_str()));
    if (ChecksumsSha1.empty() == false)
@@ -1075,8 +1076,8 @@ bool ReleaseWriter::DoPackage(string FileName)
 
    CheckSums[NewFileName].size = fd.Size();
 
-   Hashes hs;
-   hs.AddFD(fd, 0, DoHashes);
+   Hashes hs(DoHashes);
+   hs.AddFD(fd);
    CheckSums[NewFileName].Hashes = hs.GetHashStringList();
    fd.Close();