Re: xhash and it's key

2014-08-29 Thread Tomasz Sterna
Dnia 2014-08-28, czw o godzinie 17:51 +, Shawn Debnath pisze: The problem is that it breaks scenarios where the user may use a temp buffer to build the key, then insert or put it in the xhash and then free the buffer memory. This is invalid use of xhash. Assumption here is that xhash

Re: xhash and it's key

2014-08-29 Thread Shawn Debnath
Could you rethink your design to include the identifier as a part of the object it names? Yep, looks like this is a cleaner way out.

xhash and it's key

2014-08-28 Thread Shawn Debnath
Hey there, Turns out that when inserting items in xhash, the code stores a pointer to the key passed in by the user in the xhash node and uses that later to compare in _get. The problem is that it breaks scenarios where the user may use a temp buffer to build the key, then insert or put it in the

Re: xhash and it's key

2014-08-28 Thread Shawn Debnath
Pull request #79 submitted. https://github.com/jabberd2/jabberd2/pull/79 On 8/28/14, 10:51, Shawn Debnath sh...@debnath.net wrote: Hey there, Turns out that when inserting items in xhash, the code stores a pointer to the key passed in by the user in the xhash node and uses that later to