From d59b27d5fcc346d96072ed0edb88cda0223be084 Mon Sep 17 00:00:00 2001 From: Pascal Rigaux Date: Thu, 9 Dec 1999 00:52:32 +0000 Subject: no_comment --- perl-install/interactive.pm | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'perl-install/interactive.pm') diff --git a/perl-install/interactive.pm b/perl-install/interactive.pm index 6686f2999..824bd795f 100644 --- a/perl-install/interactive.pm +++ b/perl-install/interactive.pm @@ -39,11 +39,16 @@ sub new($) { } sub vnew { + my ($type, $su) = @_; + $su = $su eq "su"; require c; if (c::Xtest($ENV{DISPLAY} ||= ":0")) { + $su && $> && exec "kdesu", "-c", "$0 @ARGV"; require interactive_gtk; interactive_gtk->new; } else { + $su && $> && die "you must be root to run this program"; + require 'log.pm'; undef *log::l; *log::l = sub {}; # otherwise, it will bother us :( require interactive_newt; @@ -51,6 +56,9 @@ sub vnew { } } +sub end {} +sub exit { exit($_[0]) } + #-###################################################################################### #- Interactive functions #-###################################################################################### -- cgit v1.2.1