aboutsummaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorAngelo Naselli <anaselli@linux.it>2014-07-10 09:25:57 +0200
committerAngelo Naselli <anaselli@linux.it>2014-07-10 09:25:57 +0200
commit48b22dca97fa8a84912a60bc835645e8fbbe1952 (patch)
tree85c639e65f16569fe5bed86edb5793f83d9d5b11 /lib
parent1cd05d978ae67c7efebab7ca33c35a7cc4e4e668 (diff)
downloadcolin-keep-48b22dca97fa8a84912a60bc835645e8fbbe1952.tar
colin-keep-48b22dca97fa8a84912a60bc835645e8fbbe1952.tar.gz
colin-keep-48b22dca97fa8a84912a60bc835645e8fbbe1952.tar.bz2
colin-keep-48b22dca97fa8a84912a60bc835645e8fbbe1952.tar.xz
colin-keep-48b22dca97fa8a84912a60bc835645e8fbbe1952.zip
Changed to is_root_capability_required atm to avoid redeclarations
Diffstat (limited to 'lib')
-rw-r--r--lib/AdminPanel/Privileges.pm4
-rw-r--r--lib/AdminPanel/Rpmdragora/init.pm2
2 files changed, 3 insertions, 3 deletions
diff --git a/lib/AdminPanel/Privileges.pm b/lib/AdminPanel/Privileges.pm
index d46217d..50033c7 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 9349894..00d07c4 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;