diff options
author | Daouda Lo <daouda@mandriva.com> | 2001-09-20 14:57:37 +0000 |
---|---|---|
committer | Daouda Lo <daouda@mandriva.com> | 2001-09-20 14:57:37 +0000 |
commit | 436d2d46e759de10ceecdfbdae0b2b5d8975884b (patch) | |
tree | 7babe1674f64ebe7e501c4158b937dd28529d07d /mdkonline | |
parent | b47fa1c7584513ca594e276cbb852044194c8d8b (diff) | |
download | mgaonline-436d2d46e759de10ceecdfbdae0b2b5d8975884b.tar mgaonline-436d2d46e759de10ceecdfbdae0b2b5d8975884b.tar.gz mgaonline-436d2d46e759de10ceecdfbdae0b2b5d8975884b.tar.bz2 mgaonline-436d2d46e759de10ceecdfbdae0b2b5d8975884b.tar.xz mgaonline-436d2d46e759de10ceecdfbdae0b2b5d8975884b.zip |
launch $BROWSER with user perm
Diffstat (limited to 'mdkonline')
-rwxr-xr-x | mdkonline | 15 |
1 files changed, 8 insertions, 7 deletions
@@ -221,16 +221,16 @@ sub on_prev_clicked { sub subscribe_mdkonline() { my $browser=$ENV{'BROWSER'}; - #my $initial_user=$ENV{'INITIAL_USER'}; - #my $user_current=$ENV{'USER'}; + my $initial_user=$ENV{'INITIAL_USER'}; + my $user_current=$ENV{'USER'}; if (!$browser) {splash_warning( " ". _("Warning: No browser specified") ." "); return;} -# if ($initial_user ne "root" && $initial_user ne undef) { -# system("su -m -l $initial_user -c \"$browser $link_to_mdkonline &\""); - -# } else { - system("$browser $link_to_mdkonline &"); + if ($initial_user ne "root" && $initial_user ne undef) { + system("su -m -l $initial_user -c \"$browser $link_to_mdkonline &\""); + } else { + system("$browser $link_to_mdkonline &"); + } } sub test_passwd () { @@ -329,6 +329,7 @@ sub send_config { # wizard => ["/root/$login.$passwd.online.log.bz2.uue"] # ]); my $response = $ua->request(POST 'http://upload.mandrakeonline.net/wizard.php', + Content_Type => 'form-data', Content => [submit => "upload_wizard", wizard => ["/root/$login.$passwd.online.log.bz2.uue"] |