# HG changeset patch # User robcast # Date 1052165781 -7200 # Node ID 79a8daf6952a2598486dc1b1bcc5fa1fe0e84a80 # Parent 5279cd1d692b1cccb85b322b5fac528cbc469465 Small bug lead to null pointer exception when directory doesn't exist. diff -r 5279cd1d692b -r 79a8daf6952a servlet/src/digilib/io/DocuDirCache.java --- a/servlet/src/digilib/io/DocuDirCache.java Mon May 05 18:42:58 2003 +0200 +++ b/servlet/src/digilib/io/DocuDirCache.java Mon May 05 22:16:21 2003 +0200 @@ -115,11 +115,14 @@ return null; } } else { - // not a real cache miss then + // then it was not a real cache miss misses--; } // get the file's index n = dd.indexOf(f.getName()); + } else { + // it's not even a file :-( + return null; } } } else { @@ -177,6 +180,9 @@ // not a real cache miss then misses--; } + } else { + // it's not even a file :-( + return null; } } } else {