summaryrefslogtreecommitdiff
path: root/apt-inst/extract.cc
diff options
context:
space:
mode:
Diffstat (limited to 'apt-inst/extract.cc')
-rw-r--r--apt-inst/extract.cc17
1 files changed, 12 insertions, 5 deletions
diff --git a/apt-inst/extract.cc b/apt-inst/extract.cc
index 2c95fba92..b60784450 100644
--- a/apt-inst/extract.cc
+++ b/apt-inst/extract.cc
@@ -10,7 +10,7 @@
object is unpacked to '.dpkg.new' then the original is hardlinked to
'.dpkg.tmp' and finally the new object is renamed to overwrite the old
one. From an external perspective the file never ceased to exist.
- After the archive has been sucessfully unpacked the .dpkg.tmp files
+ After the archive has been successfully unpacked the .dpkg.tmp files
are erased. A failure causes all the .dpkg.tmp files to be restored.
Decisions about unpacking go like this:
@@ -22,7 +22,7 @@
[Note, this is reduced to only check if a file was expected to be
there]
- If the existing link/file is not a directory then it is replaced
- irregardless
+ regardless
- If the existing link/directory is being replaced by a directory then
absolutely nothing happens.
- If the existing link/directory is being replaced by a link then
@@ -50,13 +50,20 @@
#include <apt-pkg/error.h>
#include <apt-pkg/debversion.h>
#include <apt-pkg/fileutl.h>
+#include <apt-pkg/dirstream.h>
+#include <apt-pkg/filelist.h>
+#include <apt-pkg/mmap.h>
+#include <apt-pkg/pkgcache.h>
+#include <apt-pkg/cacheiterators.h>
+#include <string.h>
+#include <string>
#include <sys/stat.h>
#include <stdio.h>
-#include <unistd.h>
#include <errno.h>
#include <dirent.h>
#include <iostream>
+
#include <apti18n.h>
/*}}}*/
using namespace std;
@@ -79,7 +86,7 @@ pkgExtract::pkgExtract(pkgFLCache &FLCache,pkgCache::VerIterator Ver) :
// Extract::DoItem - Handle a single item from the stream /*{{{*/
// ---------------------------------------------------------------------
/* This performs the setup for the extraction.. */
-bool pkgExtract::DoItem(Item &Itm,int &Fd)
+bool pkgExtract::DoItem(Item &Itm, int &/*Fd*/)
{
/* Strip any leading/trailing /s from the filename, then copy it to the
temp buffer and re-apply the leading / We use a class variable
@@ -253,7 +260,7 @@ bool pkgExtract::DoItem(Item &Itm,int &Fd)
// Extract::Finished - Sequence finished, erase the temp files /*{{{*/
// ---------------------------------------------------------------------
/* */
-bool pkgExtract::Finished()
+APT_CONST bool pkgExtract::Finished()
{
return true;
}