Re: crashing vpn properties (patch)

2007-12-11 Thread Dan Williams
On Mon, 2007-12-10 at 22:59 -0600, Casey Harkins wrote: > Casey Harkins wrote: > >> Actually, whenever anything stuffs stuff into that table it needs to > >> g_strdup() the key. See update_one_secret() and copy_hash(). > >> Otherwise, you'll leak the keys when freeing the hash. So anything that >

Re: crashing vpn properties (patch)

2007-12-11 Thread Dan Williams
On Mon, 2007-12-10 at 22:53 -0600, Casey Harkins wrote: > Dan Williams wrote: > > On Mon, 2007-12-10 at 16:23 -0600, Casey Harkins wrote: > >> The crashes when working with vpn properties (not just openvpn) are the > >> result of using g_free() as the key_destroy_func. The keys being used > >> fo

Re: crashing vpn properties (patch)

2007-12-10 Thread Casey Harkins
Casey Harkins wrote: Actually, whenever anything stuffs stuff into that table it needs to g_strdup() the key. See update_one_secret() and copy_hash(). Otherwise, you'll leak the keys when freeing the hash. So anything that uses NMSettingVPNProperties (like the properties dialogs) also need to g

Re: crashing vpn properties (patch)

2007-12-10 Thread Casey Harkins
Dan Williams wrote: On Mon, 2007-12-10 at 16:23 -0600, Casey Harkins wrote: The crashes when working with vpn properties (not just openvpn) are the result of using g_free() as the key_destroy_func. The keys being used for the properties hash table are #define'ed constants and shouldn't be free

Re: crashing vpn properties (patch)

2007-12-10 Thread Dan Williams
On Mon, 2007-12-10 at 16:23 -0600, Casey Harkins wrote: > The crashes when working with vpn properties (not just openvpn) are the > result of using g_free() as the key_destroy_func. The keys being used > for the properties hash table are #define'ed constants and shouldn't be > free'ed. Attached

crashing vpn properties (patch)

2007-12-10 Thread Casey Harkins
The crashes when working with vpn properties (not just openvpn) are the result of using g_free() as the key_destroy_func. The keys being used for the properties hash table are #define'ed constants and shouldn't be free'ed. Attached is a one-liner that should fix this. This should resolve RH bu