t_dictionary lock behavior…

Jul 8, 2012 at 5:32am

t_dictionary lock behavior…


• What’s happened if a t_dictionary entry is removed/added by a thread while another thread is reading it by dictionary_getkeys / dictionary_freekeys approach ?

1. is there a global dictionary lock opened by getkeys and closed by freekeys ?
2. is the list of keys kindly updated ?
3. is the list of keys just not match anymore ?

• Is there any documentation/topic somewhere about the granularity of the t_dictionary ; for example is the copyunique operation is protected as a whole or just like a bunch of read/write operations ?

Jul 11, 2012 at 4:34pm

The result of the operation is undefined. You need to take care of your own thread-safety for this case.


Jul 12, 2012 at 3:05pm


thanks Timothy… but i bump the second point :

Is there any information about the “copyunique” thread-safety somewhere ; is it globally locked or do i have to use my own mutex too ?


You must be logged in to reply to this topic.