From 5928010bb01ec2fe7db3d1bd18062bc25380544b Mon Sep 17 00:00:00 2001 From: Norbert Preining Date: Wed, 2 Sep 2009 22:23:06 +0000 Subject: make tlmgr option multiuser behave reasonable on w32 non-admin accounts git-svn-id: svn://tug.org/texlive/trunk@15003 c570f23f-e606-0410-a88d-b1316a301751 --- Master/texmf/scripts/texlive/tlmgr.pl | 17 +++++++++++++++-- 1 file changed, 15 insertions(+), 2 deletions(-) (limited to 'Master/texmf/scripts') diff --git a/Master/texmf/scripts/texlive/tlmgr.pl b/Master/texmf/scripts/texlive/tlmgr.pl index 59718ab5a28..ad2a3ac4d77 100755 --- a/Master/texmf/scripts/texlive/tlmgr.pl +++ b/Master/texmf/scripts/texlive/tlmgr.pl @@ -2573,9 +2573,22 @@ sub action_option { } elsif ($what eq $TLPDBOptions{"w32_multi_user"}->[2]) { # when running w32 do not allow that a non-admin users sets # this from false to true - if (win32() && !admin() && !$val) { - tlwarn("tlmgr: non-admin user cannot set $TLPDBOptions{'w32_multi_user'}->[2] option to true\n"); + my $do_it = 0; + if (win32()) { + if (admin()) { + $do_it = 1; + } else { + if ($val) { + # non admin and tries to set to true, warn + tlwarn("tlmgr: non-admin user cannot set $TLPDBOptions{'w32_multi_user'}->[2] option to true\n"); + } else { + $do_it = 1; + } + } } else { + $do_it = 1; + } + if ($do_it) { if ($val) { info("tlmgr: setting option $what to 1.\n"); $localtlpdb->option($opt, 1); -- cgit v1.2.3