Re: freeing hash nodes (Re: GNOME CVS: glib johnsonm)




Tim Janik writes:
>i've discussed matters a bit with josh on irc, and what we came up with
>are basically two possibilities (josh may jump on me if i left out
>some important aspects ;).
>note however, that for either possibility, the value and key need to
>be freed from different functions, because keys and values can be
>removed out of order.

Hm, I just figured that you could always get at the value to remove it,
but not the key.  You won't hurt my feelings one bit by removing my
code and putting in a more general mechanism.  I don't have an opinion
between your two proposed interfaces, my only opinion is that if you
are going to change it, best to do it before gtk 1.2 so that no one
asks that g_hash_table_set_key_freefunc() stays.

michaelkjohnson

"Magazines all too frequently lead to books and should be regarded by the
 prudent as the heavy petting of literature."            -- Fran Lebowitz
 Linux Application Development       http://www.redhat.com/~johnsonm/lad/



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]