Minor tweaks / simplifications and refactorings.
Fixed assert for maximum hash table size (incorrect comparison).
When resizing the table, use 4x more buckets (instead of 2x).

This ratio conforms to HTAB_BUCKET_STEP=5 and HTAB_BUCKET_LIMIT=20, so
the resizing should not require too much repalloc and it also wastes very
little memory.