Fix a copy/paste mistake in richhash.

While here, don't use hardcoded numbers. Use the macros.
Merge pull request #186 from wxsBSD/length_fix

Fix a copy/paste mistake in richhash.