From 869bbd7a40e218e70ddba8e995b7edc834df0547 Mon Sep 17 00:00:00 2001 From: Olivier Blin Date: Fri, 10 Jun 2005 04:46:51 +0000 Subject: inline AmIRoot and fix perl_checker warning --- drakpxelinux.pl | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) (limited to 'drakpxelinux.pl') diff --git a/drakpxelinux.pl b/drakpxelinux.pl index 9e17139..3341a15 100644 --- a/drakpxelinux.pl +++ b/drakpxelinux.pl @@ -42,14 +42,11 @@ use constant FALSE => 0; use constant TRUE => 1; -sub AmIRoot() { - unless ($> == 0) { - err_dialog(N("Error!"), N("You are not root. Exiting...")) and !$::testing && die; - } +unless ($> == 0) { + err_dialog(N("Error!"), N("You are not root. Exiting...")); + die unless $::testing; } -AmIRoot(); - # ie of entry menu in PXE: #label linux # KERNEL images/vmlinuz -- cgit v1.2.1