diff options
Diffstat (limited to 'nisautofs_wizard')
-rw-r--r-- | nisautofs_wizard/Nisautofs.pm | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/nisautofs_wizard/Nisautofs.pm b/nisautofs_wizard/Nisautofs.pm index da0b438f..614d4222 100644 --- a/nisautofs_wizard/Nisautofs.pm +++ b/nisautofs_wizard/Nisautofs.pm @@ -233,7 +233,8 @@ sub needed_service { sub get_nis_users { my @unwanted = qw(install maui nobody mpi); my @users; - open(PASS, "ypcat passwd|") || die " cant exec ypcat passwd!"; + local *PASS; + open(PASS, "ypcat passwd|") or die " cant exec ypcat passwd!"; while (<PASS>) { my ($login) = split(':'); if (!member($login, @unwanted)) { @@ -319,7 +320,7 @@ sub do_it_server { # update nfs to fit nis nfs_home_nis(); # restart all needed services - map { needed_service($_); $_ } qw(ypserv nfs); + needed_service($_) foreach qw(ypserv nfs); undef $w; } @@ -336,12 +337,12 @@ sub do_it_client { update_yp(chomp_($o->{var}{NISDOMAIN}), chomp_($o->{var}{NISSERVER})); # update conf file update_network(); - map { needed_service($_); $_ } qw(ypbind autofs); + needed_service($_) foreach qw(ypbind autofs); undef $w; } sub new { - my ($class, $conf) = @_; + my ($class) = @_; bless { o => $o, }, $class; |