Merge pull request #1748 from lilydjwg/fix-zombies

fixes https://github.com/Alexays/Waybar/issues/1713
This commit is contained in:
Alex 2022-11-23 21:31:47 +01:00 committed by GitHub
commit ce8ae5bf17
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -21,6 +21,7 @@ waybar::modules::Custom::Custom(const std::string& name, const std::string& id,
waybar::modules::Custom::~Custom() { waybar::modules::Custom::~Custom() {
if (pid_ != -1) { if (pid_ != -1) {
killpg(pid_, SIGTERM); killpg(pid_, SIGTERM);
waitpid(pid_, NULL, 0);
pid_ = -1; pid_ = -1;
} }
} }