diff options
author | Slávek Banko <slavek.banko@axis.cz> | 2012-07-11 18:52:21 +0200 |
---|---|---|
committer | Slávek Banko <slavek.banko@axis.cz> | 2012-07-11 19:03:16 +0200 |
commit | a30de704f1cf6e764fb23e0ca948564e8815fa25 (patch) | |
tree | 1764061f60ebb03fcaff762722fabbc0f8f1942d | |
parent | 7f3ab86eddd7733c988215ffcffb1f1ba8166a86 (diff) | |
download | tdeutils-a30de704f1cf6e764fb23e0ca948564e8815fa25.tar.gz tdeutils-a30de704f1cf6e764fb23e0ca948564e8815fa25.zip |
Fix klaptopdaemon setupHandler to be distribution independent
Thanks to Francois Andriot
(cherry picked from commit 1e1a776f0dbd9ef9816902299bf6246f93a888ca)
-rw-r--r-- | klaptopdaemon/acpi.cpp | 2 | ||||
-rw-r--r-- | klaptopdaemon/apm.cpp | 4 |
2 files changed, 3 insertions, 3 deletions
diff --git a/klaptopdaemon/acpi.cpp b/klaptopdaemon/acpi.cpp index caab4ab..f7e8d97 100644 --- a/klaptopdaemon/acpi.cpp +++ b/klaptopdaemon/acpi.cpp @@ -178,7 +178,7 @@ void AcpiConfig::setupHelper() proc << kdesu; proc << "-u"; proc << "root"; - proc << "dpkg-statoverride --update --add root root 6755 "+helper; + proc << "chown root "+helper+"; chmod +s "+helper; proc.start(KProcess::Block); // run it sync so has_acpi below sees the results } } else { diff --git a/klaptopdaemon/apm.cpp b/klaptopdaemon/apm.cpp index b31efc7..4850f76 100644 --- a/klaptopdaemon/apm.cpp +++ b/klaptopdaemon/apm.cpp @@ -166,7 +166,7 @@ void ApmConfig::setupHelper() proc << kdesu; proc << "-u"; proc << "root"; - proc << TQString("dpkg-statoverride --update --add root root 6755 ")+apm_name; + proc << TQString("chown root ")+apm_name+TQString("; chmod +s ")+apm_name; proc.start(KProcess::Block); // run it sync so has_apm below sees the results } } else { @@ -200,7 +200,7 @@ void ApmConfig::setupHelper2() // we use the acpi helper to do software suspend proc << kdesu; proc << "-u"; proc << "root"; - proc << "dpkg-statoverride --update --add root root 6755 "+helper; + proc << "chown root "+helper+"; chmod +s "+helper; proc.start(KProcess::Block); // run it sync so has_acpi below sees the results } } else { |