Fixed bug when properties were not updated when

passwd file was removed.
This commit is contained in:
hns 2001-03-22 17:57:56 +00:00
parent bfc17b11a1
commit 2ba56a02cb

View file

@ -25,8 +25,10 @@ public class CryptFile {
public boolean authenticate (String username, String pw) {
if (file.exists() && file.lastModified () > lastRead)
if (file.exists () && file.lastModified () > lastRead)
readFile ();
else if (!file.exists () && users.size () > 0)
users.clear ();
String realpw = users.getProperty (username);
if (realpw != null) {
// check if password matches