Can MD5ing all the files in a table cause a memory leak? I'm running this code with the FastMD5 library. Could it lead to memory leaks, or does it seem OK?

File[] directory = new File("/PATH/TO/FOLDER/WITH/LOTS/OF/FILES").listFiles();

    for(int i = 0; i &lt; directory.length;i++){

    System.out.println(MD5.asHex(MD5.getHash(directory[i])));

    }
In Java you have to do so much hard work to leak memory (someone will say not closing stream, but that's another story). 

I think you have a C programming background. So you are thinking of memory leak. Forget it there is JVM for you.

And use enhanced for loop in Java as much as you can...

for(File file : directory) {
    System.out.println(MD5.asHex(MD5.getHash(file)));
}