cleaned up hash.c