if head is a function parameter and not a global variable then head is not properly initialized. a small example is attached, in add( ... ) the assertion after HASH_ADD_KEYPTR goes through, but in main function it fails.
my fault, sorry
my fault, sorry