Overview

HTTPS SSH

Hsearch_rw

Hsearch_rw is a wrapper of hsearch_r (hash table routines supported by glibc) coming with more practical functions.

Quick usage

$ cd src
$ gcc hsearch_rw.c example.c -o example
$ ./example

Features

Hsearch_rw implements the following features that hsearch_r does not support.

  • Auto stretch
  • Item removal
  • Foreach function
  • Retrieve key/value list
  • Key/value iteration

No third party library is needed except for glibc. Hsearch_r and tsearch, both of which are provided by glibc, are internally used for managing hash tables and keys respectively.

License

MIT. See COPYING