diff options
author | David Kalnischkies <kalnischkies@gmail.com> | 2011-12-17 23:53:31 +0100 |
---|---|---|
committer | David Kalnischkies <kalnischkies@gmail.com> | 2011-12-17 23:53:31 +0100 |
commit | 109eb1511d0cdfa4af3196105cada30bcbb77bc8 (patch) | |
tree | c07319a3ddc9a6484561d1cea918aaecade4a7e9 /apt-pkg/acquire-item.cc | |
parent | 1abbc47c045770476f5f9a57c58989d13290d51b (diff) |
try to avoid direct usage of .Fd() if possible and do read()s and co
on the FileFd instead
Diffstat (limited to 'apt-pkg/acquire-item.cc')
-rw-r--r-- | apt-pkg/acquire-item.cc | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/apt-pkg/acquire-item.cc b/apt-pkg/acquire-item.cc index 453fce109..f231c42b4 100644 --- a/apt-pkg/acquire-item.cc +++ b/apt-pkg/acquire-item.cc @@ -438,7 +438,7 @@ bool pkgAcqDiffIndex::ParseDiffIndex(string IndexDiffFile) /*{{{*/ FileFd fd(CurrentPackagesFile, FileFd::ReadOnly); SHA1Summation SHA1; - SHA1.AddFD(fd.Fd(), fd.Size()); + SHA1.AddFD(fd); string const local_sha1 = SHA1.Result(); if(local_sha1 == ServerSha1) @@ -669,7 +669,7 @@ bool pkgAcqIndexDiffs::QueueNextDiff() /*{{{*/ FileFd fd(FinalFile, FileFd::ReadOnly); SHA1Summation SHA1; - SHA1.AddFD(fd.Fd(), fd.Size()); + SHA1.AddFD(fd); string local_sha1 = string(SHA1.Result()); if(Debug) std::clog << "QueueNextDiff: " |