libpurple/log.c

branch
soc.2013.gobjectification.plugins
changeset 37134
07746c9a04bf
parent 37095
0196a853776e
parent 35813
a5b71a95a42a
child 37135
6271bcdee576
--- a/libpurple/log.c	Mon Apr 07 20:02:22 2014 +0530
+++ b/libpurple/log.c	Fri Apr 11 16:23:12 2014 +0530
@@ -24,11 +24,11 @@
 #include "dbus-maybe.h"
 #include "debug.h"
 #include "glibcompat.h"
+#include "image-store.h"
 #include "log.h"
 #include "prefs.h"
 #include "util.h"
 #include "stringref.h"
-#include "imgstore.h"
 #include "time.h"
 
 static GSList *loggers = NULL;
@@ -797,7 +797,9 @@
 }
 
 /* NOTE: This can return msg (which you may or may not want to g_free())
- * NOTE: or a newly allocated string which you MUST g_free(). */
+ * NOTE: or a newly allocated string which you MUST g_free().
+ * TODO: XXX: does it really works?
+ */
 static char *
 convert_image_tags(const PurpleLog *log, const char *msg)
 {
@@ -827,13 +829,13 @@
 		{
 			FILE *image_file;
 			char *dir;
-			PurpleStoredImage *image;
+			PurpleImage *image;
 			gconstpointer image_data;
 			char *new_filename = NULL;
 			char *path = NULL;
 			size_t image_byte_count;
 
-			image = purple_imgstore_find_by_id(imgid);
+			image = purple_image_store_get(imgid);
 			if (image == NULL)
 			{
 				/* This should never happen. */
@@ -842,8 +844,8 @@
 				g_return_val_if_reached((char *)msg);
 			}
 
-			image_data       = purple_imgstore_get_data(image);
-			image_byte_count = purple_imgstore_get_size(image);
+			image_data       = purple_image_get_data(image);
+			image_byte_count = purple_image_get_size(image);
 			dir              = purple_log_get_log_dir(log->type, log->name, log->account);
 			new_filename     = purple_util_get_image_filename(image_data, image_byte_count);
 

mercurial