[Telepathy-commits] [telepathy-gabble/master] Free the buffers when the SOCKS5 GIOChannel is closed
Marco Barisione
marco at barisione.org
Tue Jan 6 08:41:25 PST 2009
---
src/bytestream-socks5.c | 12 ++++++++++++
1 files changed, 12 insertions(+), 0 deletions(-)
diff --git a/src/bytestream-socks5.c b/src/bytestream-socks5.c
index 39dcf6d..ff27c70 100644
--- a/src/bytestream-socks5.c
+++ b/src/bytestream-socks5.c
@@ -444,6 +444,18 @@ socks5_close_channel (GabbleBytestreamSocks5 *self)
priv->error_watch = 0;
}
+ if (priv->read_buffer)
+ {
+ g_string_free (priv->read_buffer, TRUE);
+ priv->read_buffer = NULL;
+ }
+
+ if (priv->write_buffer)
+ {
+ g_string_free (priv->write_buffer, TRUE);
+ priv->write_buffer = NULL;
+ }
+
g_io_channel_unref (priv->io_channel);
priv->io_channel = NULL;
}
--
1.5.6.5
More information about the Telepathy-commits
mailing list