diff options
author | Sam Bingner <sam@bingner.com> | 2018-12-26 13:07:23 -1000 |
---|---|---|
committer | Sam Bingner <sam@bingner.com> | 2018-12-26 14:51:59 -1000 |
commit | 59c3e0b998fd69532159d8dc416109cf50651482 (patch) | |
tree | 2e58bef1273e4d3542c168980e4a2d793e170045 /apt-pkg/deb/dpkgpm.cc | |
parent | ac0d26d4e39da16bdbf575637fd3d4b24a7fb4b8 (diff) | |
parent | 2aa218273eb6009880e987f90d3e24b8efb04642 (diff) |
Merge nitotv apt fixes into 1.4.81.4.8+nitotv
Diffstat (limited to 'apt-pkg/deb/dpkgpm.cc')
-rw-r--r-- | apt-pkg/deb/dpkgpm.cc | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/apt-pkg/deb/dpkgpm.cc b/apt-pkg/deb/dpkgpm.cc index 80bee03dd..01282efcc 100644 --- a/apt-pkg/deb/dpkgpm.cc +++ b/apt-pkg/deb/dpkgpm.cc @@ -1386,7 +1386,9 @@ static void cleanUpTmpDir(char * const tmpdir) /*{{{*/ if (unlikely(Ent->d_type != DT_LNK && Ent->d_type != DT_UNKNOWN)) continue; #endif - if (unlikely(unlinkat(dfd, Ent->d_name, 0) != 0)) + char path[strlen(tmpdir) + 1 + strlen(Ent->d_name) + 1]; + sprintf(path, "%s/%s", tmpdir, Ent->d_name); + if (unlikely(unlink(path) != 0)) break; } closedir(D); @@ -1697,7 +1699,7 @@ bool pkgDPkgPM::Go(APT::Progress::PackageManager *progress) bool dpkgMultiArch = debSystem::SupportsMultiArch(); // start pty magic before the loop - StartPtyMagic(); + //StartPtyMagic(); or not... // Tell the progress that its starting and fork dpkg d->progress->Start(d->master); @@ -1758,6 +1760,7 @@ bool pkgDPkgPM::Go(APT::Progress::PackageManager *progress) case Item::Remove: case Item::Purge: ADDARGC("--force-depends"); + ADDARGC("--force-remove-reinstreq"); if (std::any_of(I, J, ItemIsEssential)) ADDARGC("--force-remove-essential"); ADDARGC("--remove"); @@ -2096,7 +2099,7 @@ bool pkgDPkgPM::Go(APT::Progress::PackageManager *progress) } } // dpkg is done at this point - StopPtyMagic(); + //StopPtyMagic(); CloseLog(); if (d->dpkg_error.empty() == false) |