Add re-entrant versions of the hash functions based on the GNU api.

While testing this I found a conformance issue in hdestroy()
that will be fixed in a subsequent commit.

Obtained from:	NetBSD (hcreate.c, CVS Rev. 1.7)
Update license.

NetBSD has removed the advertisement clause from this file.

Obtained from:	NetBSD (CVS rev. 1,8)