Commit 054c2cec authored by Leigh Stoller's avatar Leigh Stoller

Minor bug fix to SetPassword(); make $expires has a value.

parent f1ba32f4
......@@ -1248,7 +1248,7 @@ sub SSLPassPhrase($$$)
#
# Set password for user.
#
sub SetPassword($$$)
sub SetPassword($$;$)
{
my ($self, $encoding, $expires) = @_;
my $safe_encoding = DBQuoteSpecial($encoding);
......@@ -1259,6 +1259,9 @@ sub SetPassword($$$)
my $uid_idx = $self->uid_idx();
$expires = "date_add(now(), interval 1 year)"
if (!defined($expires));
# Clear the chpasswd stuff anytime passwd is set.
return -1
if (! DBQueryWarn("update users set ".
......
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