If the hash table removed the object but failed to rehash shouldn't be reported as
an error by returning NULL.
BUGFIX: objects were unintentionally freed when insertion failed.

BUGFIX: RCHashTable_remove_sync() left the table's mutex locked if key wasn't found.
Also added previous commit's bugfix.

BUGFIX: RCHashTable_refdec_sync() also left the table's mutex locked if key wasn't
found.