aboutsummaryrefslogtreecommitdiffstats
path: root/libempathy
diff options
context:
space:
mode:
authorEmilio Pozuelo Monfort <emilio.pozuelo@collabora.co.uk>2011-04-25 19:07:59 +0800
committerEmilio Pozuelo Monfort <emilio.pozuelo@collabora.co.uk>2011-06-09 19:34:54 +0800
commit9f9677ec63954a870daadfedd51359a631c43ea2 (patch)
treea989fcf1adbf41edbfd5803e736e02f4c671bcaf /libempathy
parent62f5ed896ad09c54be054f6872a69b905db3b8c7 (diff)
downloadgsoc2013-empathy-9f9677ec63954a870daadfedd51359a631c43ea2.tar
gsoc2013-empathy-9f9677ec63954a870daadfedd51359a631c43ea2.tar.gz
gsoc2013-empathy-9f9677ec63954a870daadfedd51359a631c43ea2.tar.bz2
gsoc2013-empathy-9f9677ec63954a870daadfedd51359a631c43ea2.tar.lz
gsoc2013-empathy-9f9677ec63954a870daadfedd51359a631c43ea2.tar.xz
gsoc2013-empathy-9f9677ec63954a870daadfedd51359a631c43ea2.tar.zst
gsoc2013-empathy-9f9677ec63954a870daadfedd51359a631c43ea2.zip
Add _tpl_action_chain_clear
Diffstat (limited to 'libempathy')
-rw-r--r--libempathy/action-chain-internal.h1
-rw-r--r--libempathy/action-chain.c7
2 files changed, 8 insertions, 0 deletions
diff --git a/libempathy/action-chain-internal.h b/libempathy/action-chain-internal.h
index d2395d172..14750c938 100644
--- a/libempathy/action-chain-internal.h
+++ b/libempathy/action-chain-internal.h
@@ -42,6 +42,7 @@ void _tpl_action_chain_prepend (TplActionChain *self, TplPendingAction func,
void _tpl_action_chain_start (TplActionChain *self);
void _tpl_action_chain_continue (TplActionChain *self);
void _tpl_action_chain_terminate (TplActionChain *self, const GError *error);
+void _tpl_action_chain_clear (TplActionChain *self);
gpointer _tpl_action_chain_get_object (TplActionChain *self);
gboolean _tpl_action_chain_new_finish (GObject *source,
diff --git a/libempathy/action-chain.c b/libempathy/action-chain.c
index 30217ddc5..b6bf25ab9 100644
--- a/libempathy/action-chain.c
+++ b/libempathy/action-chain.c
@@ -137,6 +137,13 @@ _tpl_action_chain_continue (TplActionChain *self)
void
+_tpl_action_chain_clear (TplActionChain *self)
+{
+ g_queue_foreach (self->chain, (GFunc) link_free, NULL);
+ g_queue_clear (self->chain);
+}
+
+void
_tpl_action_chain_terminate (TplActionChain *self,
const GError *error)
{