mirror of
https://github.com/profanity-im/profanity.git
synced 2024-11-03 19:37:16 -05:00
separate glib allocator and stdlib malloc/free
Memory allocated by glib should be freed by g_free. Probably g_free calls stdlib free, but in order to avoid portability issues better use g_free as described in glib documentation.
This commit is contained in:
parent
f2638e001a
commit
7b37f2ace7
12
src/jid.c
12
src/jid.c
@ -108,12 +108,12 @@ void
|
|||||||
jid_destroy(Jid *jid)
|
jid_destroy(Jid *jid)
|
||||||
{
|
{
|
||||||
if (jid != NULL) {
|
if (jid != NULL) {
|
||||||
FREE_SET_NULL(jid->str);
|
GFREE_SET_NULL(jid->str);
|
||||||
FREE_SET_NULL(jid->localpart);
|
GFREE_SET_NULL(jid->localpart);
|
||||||
FREE_SET_NULL(jid->domainpart);
|
GFREE_SET_NULL(jid->domainpart);
|
||||||
FREE_SET_NULL(jid->resourcepart);
|
GFREE_SET_NULL(jid->resourcepart);
|
||||||
FREE_SET_NULL(jid->barejid);
|
GFREE_SET_NULL(jid->barejid);
|
||||||
FREE_SET_NULL(jid->fulljid);
|
GFREE_SET_NULL(jid->fulljid);
|
||||||
FREE_SET_NULL(jid);
|
FREE_SET_NULL(jid);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user