fix #3721: NPE in Geocache.hashCode()

Also, hash codes must be equal when the objects compare equal. Since
equality compares only geocodes, the hash codes must also only take
geocodes into consideration.