linux上升级软件中对dpkg提权

This commit is contained in:
luoliangyi 2022-07-21 18:25:56 +08:00
parent 581d2d139e
commit bd5706e333
1 changed files with 1 additions and 1 deletions

View File

@ -138,7 +138,7 @@ bool Upgrade(const std::string& pkgPath)
}
#else
std::string cmd = "dpkg -i \"" + pkgPath + "\"";
std::string cmd = "pkexec dpkg -i \"" + pkgPath + "\"";
if (0 == system(cmd.c_str()))
ret = true;
#endif