diff libpurple/protocols/oscar/bstream.c @ 17191:1927f4ead3ca

Make all the oscar memory allocations and frees use the glib functions to avoid problems when mixing C runtimes.
author Daniel Atallah <daniel.atallah@gmail.com>
date Tue, 22 May 2007 18:56:09 +0000
parents 32c366eeeb99
children 44b4e8bd759b
line wrap: on
line diff
--- a/libpurple/protocols/oscar/bstream.c	Tue May 22 13:00:00 2007 +0000
+++ b/libpurple/protocols/oscar/bstream.c	Tue May 22 18:56:09 2007 +0000
@@ -172,10 +172,10 @@
 {
 	guint8 *ob;
 
-	ob = malloc(len);
+	ob = g_malloc(len);
 
 	if (byte_stream_getrawbuf(bs, ob, len) < len) {
-		free(ob);
+		g_free(ob);
 		return NULL;
 	}
 
@@ -186,10 +186,10 @@
 {
 	char *ob;
 
-	ob = malloc(len + 1);
+	ob = g_malloc(len + 1);
 
 	if (byte_stream_getrawbuf(bs, (guint8 *)ob, len) < len) {
-		free(ob);
+		g_free(ob);
 		return NULL;
 	}