Added uthash malloc/free functions to make sure hash always uses standard functions; More careful about initialization and finalization state now, fixing problems that could occur after finalization.