Mercurial > pidgin
changeset 29785:51bc0be83108
Added a function to destroy JabberData instances.
To be used receiving data objects for "short-lived" objects (such as the
ones used for file transfer thumbnails, since they won't be cached).
author | Marcus Lundblad <ml@update.uu.se> |
---|---|
date | Thu, 25 Jun 2009 22:25:23 +0000 |
parents | bae447e1fa96 |
children | b6dda7d483a2 |
files | libpurple/protocols/jabber/data.c libpurple/protocols/jabber/data.h |
diffstat | 2 files changed, 10 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- a/libpurple/protocols/jabber/data.c Thu Jun 25 20:56:37 2009 +0000 +++ b/libpurple/protocols/jabber/data.c Thu Jun 25 22:25:23 2009 +0000 @@ -92,6 +92,12 @@ g_free(data); } +void +jabber_data_destroy(JabberData *data) +{ + jabber_data_delete(data); +} + const char * jabber_data_get_cid(const JabberData *data) {
--- a/libpurple/protocols/jabber/data.h Thu Jun 25 20:56:37 2009 +0000 +++ b/libpurple/protocols/jabber/data.h Thu Jun 25 22:25:23 2009 +0000 @@ -39,6 +39,10 @@ XEP 0231 */ JabberData *jabber_data_create_from_xml(xmlnode *tag); +/* destroy a JabberData instance, NOT to be used on data that has been + associated, since they get "owned" */ +void jabber_data_destroy(JabberData *data); + const char *jabber_data_get_cid(const JabberData *data); const char *jabber_data_get_type(const JabberData *data);