kevinxw created ZOOKEEPER-3088:
----------------------------------
Summary: zk c client: should delete tsd keys in a destructor
Key: ZOOKEEPER-3088
URL: https://issues.apache.org/jira/browse/ZOOKEEPER-3088
Project: ZooKeeper
Issue Type: Bug
Components: c client
Affects Versions: 3.4.12
Reporter: kevinxw
crash when unload libzookeeper_mt.so by dlclose,
the tsd keys should be deleted in a destructor in zk_log.c
{code:java}
__attribute__((destructor)) void deleteTSDKeys()
{
pthread_setspecific(time_now_buffer, NULL);
pthread_setspecific(format_log_msg_buffer, NULL);
pthread_key_delete(time_now_buffer);
pthread_key_delete(format_log_msg_buffer);
}
{code}
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)