diff options
author | Angelo Naselli <anaselli@linux.it> | 2014-07-10 09:25:57 +0200 |
---|---|---|
committer | Angelo Naselli <anaselli@linux.it> | 2014-07-10 09:25:57 +0200 |
commit | 48b22dca97fa8a84912a60bc835645e8fbbe1952 (patch) | |
tree | 85c639e65f16569fe5bed86edb5793f83d9d5b11 /lib/AdminPanel | |
parent | 1cd05d978ae67c7efebab7ca33c35a7cc4e4e668 (diff) | |
download | manatools-48b22dca97fa8a84912a60bc835645e8fbbe1952.tar manatools-48b22dca97fa8a84912a60bc835645e8fbbe1952.tar.gz manatools-48b22dca97fa8a84912a60bc835645e8fbbe1952.tar.bz2 manatools-48b22dca97fa8a84912a60bc835645e8fbbe1952.tar.xz manatools-48b22dca97fa8a84912a60bc835645e8fbbe1952.zip |
Changed to is_root_capability_required atm to avoid redeclarations
Diffstat (limited to 'lib/AdminPanel')
-rw-r--r-- | lib/AdminPanel/Privileges.pm | 4 | ||||
-rw-r--r-- | lib/AdminPanel/Rpmdragora/init.pm | 2 |
2 files changed, 3 insertions, 3 deletions
diff --git a/lib/AdminPanel/Privileges.pm b/lib/AdminPanel/Privileges.pm index d46217d3..50033c73 100644 --- a/lib/AdminPanel/Privileges.pm +++ b/lib/AdminPanel/Privileges.pm @@ -25,7 +25,7 @@ require Exporter; use base qw(Exporter); use English qw(-no_match_vars); -our @EXPORT = qw(require_root_capability +our @EXPORT = qw(is_root_capability_required ask_for_authentication); my $wrappers = { "sudo" => "/usr/bin/sudo", @@ -35,7 +35,7 @@ my $wrappers = { "sudo" => "/usr/bin/sudo", my $wrapper = 0; -sub require_root_capability { +sub is_root_capability_required { return $EUID != 0; } diff --git a/lib/AdminPanel/Rpmdragora/init.pm b/lib/AdminPanel/Rpmdragora/init.pm index 9349894b..00d07c42 100644 --- a/lib/AdminPanel/Rpmdragora/init.pm +++ b/lib/AdminPanel/Rpmdragora/init.pm @@ -149,7 +149,7 @@ if ($MODE eq 'remove') { $default_list_mode = 'all_updates'; } -$MODE eq 'update' || $rpmdragora_options{'run-as-root'} and AdminPanel::Privileges::require_root_capability(); +$MODE eq 'update' || $rpmdragora_options{'run-as-root'} and AdminPanel::Privileges::is_root_capability_required(); $::noborderWhenEmbedded = 1; require AdminPanel::rpmdragora; |