Fixed a crash if the input is null to the hash function.

Also forced the progress updates to 100 if it completes (this was causing
problems with null hashes, because it never entered the input loop and so
the progress listeners were not being updated that it was complete)