Commit 4e0ffd9c authored by Gavin Brown's avatar Gavin Brown
Browse files

fixed

parent 01bdae47
......@@ -862,8 +862,10 @@ sub generate_authinfo {
my $length = shift || 16;
my $authinfo;
my @chars = ('a'..'z'), ('A'..'Z'), (0-9), ('!', '#', '$', '%', '&', '(', ')', '*', '+', ',', '-', '.', '/', ':', ';', '<', '=', '>', '?', '[', ']', '^', '_', '{', '|', '}', '~');
$authinfo .= $chars[int(rand(scalar(@chars)))-1] while (length($authinfo) < $length);
my @chars = (('a'..'z'), ('A'..'Z'), (0-9), ('!', '#', '$', '%', '&', '(', ')', '*', '+', ',', '-', '.', '/', ':', ';', '<', '=', '>', '?', '[', ']', '^', '_', '{', '|', '}', '~'));
my $c = scalar(@chars);
$authinfo .= $chars[int($c * rand())-1] while (length($authinfo) < $length);
return $authinfo;
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment