fix various findbugs errors categorized CORRECTNESS and BAD_PRACTICE
fix bugs in mkdirs() changes
fix npe with -ea enabled
fix typo that radu wants me to fix
make a couple classes have non-null arguments
Merge pull request #962 from dwightguth/findbugs

fix various findbugs errors categorized CORRECTNESS and BAD_PRACTICE