Update Java bindings
BugFix for null write case
Respect pre-set environment variables like JAVA_HOME