[collectd] should utils_llist duplicate and own char *key?

Florian Forster octo at verplant.org
Wed Dec 12 08:48:46 CET 2007


Hi Luke,

On Tue, Dec 11, 2007 at 03:44:18PM -0800, Luke Heberling wrote:
> However, it would need to know its size and would preferably not
> duplicate and own the key for each item. Here's a patch which does
> this.

thanks :) I've applied and pushed your patch to the repository. It makes
perfectly sense to use the same semantic that's used in the AVL trees..

> [...] similar to the way the avl tree does not impose any lifetime on
> its keys. What do you guys think?

I don't fully understand what you mean by `lifetime', because if the key
is freed from outside the AVL tree the code will access invalid memory
and fial horribly at best..

Regards,
-octo
-- 
Florian octo Forster
Hacker in training
GnuPG: 0x91523C3D
http://verplant.org/
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: Digital signature
Url : http://mailman.verplant.org/pipermail/collectd/attachments/20071212/616cb8f6/attachment.pgp 


More information about the collectd mailing list