summaryrefslogtreecommitdiff
path: root/ftparchive/writer.cc
diff options
context:
space:
mode:
authorMichael Vogt <mvo@ubuntu.com>2015-05-22 14:17:04 +0200
committerMichael Vogt <mvo@ubuntu.com>2015-05-22 14:17:04 +0200
commit68be2fbb252a71303046e2ca7866cd659a91b585 (patch)
treed9ad50c5fa43943c409fed2e7e8d476f4603fd42 /ftparchive/writer.cc
parente29a7a394cfd41e8bad81535e0a8c07654f34bf6 (diff)
parent15901516326737a67f2a9af26cd7e434162de019 (diff)
Merge remote-tracking branch 'upstream/debian/sid' into debian/sid
Diffstat (limited to 'ftparchive/writer.cc')
-rw-r--r--ftparchive/writer.cc12
1 files changed, 2 insertions, 10 deletions
diff --git a/ftparchive/writer.cc b/ftparchive/writer.cc
index 7c1c9cc03..0f6cc177b 100644
--- a/ftparchive/writer.cc
+++ b/ftparchive/writer.cc
@@ -634,18 +634,10 @@ bool SourcesWriter::DoPackage(string FileName)
// the "db cursor"
Db.Finish();
- // read stuff
- char *Start = Db.Dsc.Data;
- char *BlkEnd = Db.Dsc.Data + Db.Dsc.Length;
-
- // Add extra \n to the end, just in case (as in clearsigned they are missing)
- *BlkEnd++ = '\n';
- *BlkEnd++ = '\n';
-
pkgTagSection Tags;
- if (Tags.Scan(Start,BlkEnd - Start) == false)
+ if (Tags.Scan(Db.Dsc.Data.c_str(), Db.Dsc.Data.length()) == false)
return _error->Error("Could not find a record in the DSC '%s'",FileName.c_str());
-
+
if (Tags.Exists("Source") == false)
return _error->Error("Could not find a Source entry in the DSC '%s'",FileName.c_str());
Tags.Trim();