summaryrefslogtreecommitdiff
path: root/apt-pkg/deb
diff options
context:
space:
mode:
Diffstat (limited to 'apt-pkg/deb')
-rw-r--r--apt-pkg/deb/dpkgpm.cc2
1 files changed, 1 insertions, 1 deletions
diff --git a/apt-pkg/deb/dpkgpm.cc b/apt-pkg/deb/dpkgpm.cc
index ccc4b5a6c..1446826d6 100644
--- a/apt-pkg/deb/dpkgpm.cc
+++ b/apt-pkg/deb/dpkgpm.cc
@@ -1597,7 +1597,7 @@ bool pkgDPkgPM::Go(APT::Progress::PackageManager *progress)
{
std::string const oldpkgcache = _config->FindFile("Dir::cache::pkgcache");
if (oldpkgcache.empty() == false && RealFileExists(oldpkgcache) == true &&
- unlink(oldpkgcache.c_str()) == 0)
+ RemoveFile("pkgDPkgPM::Go", oldpkgcache))
{
std::string const srcpkgcache = _config->FindFile("Dir::cache::srcpkgcache");
if (srcpkgcache.empty() == false && RealFileExists(srcpkgcache) == true)