From 60cc44d160af02c49614653c97bfa3e4e5c9601d Mon Sep 17 00:00:00 2001 From: Julian Andres Klode Date: Mon, 15 Apr 2019 11:32:50 +0200 Subject: Prevent shutdown while running dpkg As long as we are running dpkg, keep an inhibitor that blocks us from shutting down. LP: #1820886 --- apt-pkg/contrib/fileutl.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'apt-pkg/contrib/fileutl.h') diff --git a/apt-pkg/contrib/fileutl.h b/apt-pkg/contrib/fileutl.h index fff49a757..cc0191192 100644 --- a/apt-pkg/contrib/fileutl.h +++ b/apt-pkg/contrib/fileutl.h @@ -283,4 +283,6 @@ bool Popen(const char *Args[], FileFd &Fd, pid_t &Child, FileFd::OpenMode Mode, APT_HIDDEN bool OpenConfigurationFileFd(std::string const &File, FileFd &Fd); +APT_HIDDEN int Inhibit(const char *what, const char *who, const char *why, const char *mode); + #endif -- cgit v1.2.3