diff options
author | Pascal Rigaux <pixel@mandriva.com> | 2003-06-06 16:21:22 +0000 |
---|---|---|
committer | Pascal Rigaux <pixel@mandriva.com> | 2003-06-06 16:21:22 +0000 |
commit | d83ad76e30478501e59e959840d15fa9ea71e421 (patch) | |
tree | ad95db5a1178b10d9b674cbb391691f4ca4430d7 /perl-install/any.pm | |
parent | f849b68fce455b013d4493fc372e8da41147dd57 (diff) | |
download | drakx-d83ad76e30478501e59e959840d15fa9ea71e421.tar drakx-d83ad76e30478501e59e959840d15fa9ea71e421.tar.gz drakx-d83ad76e30478501e59e959840d15fa9ea71e421.tar.bz2 drakx-d83ad76e30478501e59e959840d15fa9ea71e421.tar.xz drakx-d83ad76e30478501e59e959840d15fa9ea71e421.zip |
perl_checker compliance
Diffstat (limited to 'perl-install/any.pm')
-rw-r--r-- | perl-install/any.pm | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/perl-install/any.pm b/perl-install/any.pm index aee740bfe..7134d5e16 100644 --- a/perl-install/any.pm +++ b/perl-install/any.pm @@ -550,12 +550,12 @@ sub ask_users { my %groups; my $verif = sub { - $u->{password} eq $u->{password2} or $in->ask_warn('', [ N("The passwords do not match"), N("Please try again") ]), return (1,2); - $security > 3 && length($u->{password}) < 6 and $in->ask_warn('', N("This password is too simple")), return (1,2); - $u->{name} or $in->ask_warn('', N("Please give a user name")), return (1,0); - $u->{name} =~ /^[a-z]+?[a-z0-9_-]*?$/ or $in->ask_warn('', N("The user name must contain only lower cased letters, numbers, `-' and `_'")), return (1,0); - length($u->{name}) <= 32 or $in->ask_warn('', N("The user name is too long")), return (1,0); - member($u->{name}, 'root', map { $_->{name} } @$users) and $in->ask_warn('', N("This user name has already been added")), return (1,0); + $u->{password} eq $u->{password2} or $in->ask_warn('', [ N("The passwords do not match"), N("Please try again") ]), return 1,2; + $security > 3 && length($u->{password}) < 6 and $in->ask_warn('', N("This password is too simple")), return 1,2; + $u->{name} or $in->ask_warn('', N("Please give a user name")), return 1,0; + $u->{name} =~ /^[a-z]+?[a-z0-9_-]*?$/ or $in->ask_warn('', N("The user name must contain only lower cased letters, numbers, `-' and `_'")), return 1,0; + length($u->{name}) <= 32 or $in->ask_warn('', N("The user name is too long")), return 1,0; + member($u->{name}, 'root', map { $_->{name} } @$users) and $in->ask_warn('', N("This user name has already been added")), return 1,0; return 0; }; my $ret = $in->ask_from_( |