Fix for hash randomization

This is related to #40, #44.