cpw.nader.asynclogging-3: 9491c476: Fixed up two last bugs in gnthistory.c

morshed.nader at gmail.com morshed.nader at gmail.com
Fri Jan 14 00:32:01 EST 2011


----------------------------------------------------------------------
Revision: 9491c476c58f8a95dbfd670b349316b38e0b5b22
Parent:   e36f0ae963381835a9ae02ae7fbcab99623df4ae
Author:   morshed.nader at gmail.com
Date:     01/13/11 23:47:27
Branch:   im.pidgin.cpw.nader.asynclogging-3
URL: http://d.pidgin.im/viewmtn/revision/info/9491c476c58f8a95dbfd670b349316b38e0b5b22

Changelog: 

Fixed up two last bugs in gnthistory.c

Changes against parent e36f0ae963381835a9ae02ae7fbcab99623df4ae

  patched  finch/plugins/gnthistory.c

-------------- next part --------------
============================================================
--- finch/plugins/gnthistory.c	3c6a3bfd2eb464947d0947e07d2708e08fbeef2b
+++ finch/plugins/gnthistory.c	3e57b7a27125d6f961eec7de28957613027b5dd6
@@ -203,7 +203,7 @@ historize_log_read_cb(GObject *object, G
 	GString *buffer = view->string;
 	const gchar *header_date;
 	gchar *text, *escaped_alias, *header, *full_header, *text_backup;
-	struct tm *tm;
+	const struct tm *tm;
 
 	if (res == NULL) {
 		callback_data->count--;
@@ -226,7 +226,8 @@ historize_log_read_cb(GObject *object, G
 		purple_conversation_write(c, "", "<hr>", options, time(NULL));
 
 	tm = purple_log_get_tm(log);
-	if (tm)
+
+	if (tm != NULL)
 		header_date = purple_date_format_full(tm);
 	else {
 		time_t log_time = purple_log_get_time(log);
@@ -365,7 +366,7 @@ historize_log_free(_historize_callback_d
 historize_log_free(_historize_callback_data *callback_data)
 {
 	if (callback_data->log != NULL)
-		purple_log_free(callback_data->log);
+		g_object_unref(callback_data->log);
 
 	// Why on earth does pidgin give us gulong to refer to our connected signal if it
 	// offers no API to disconnect it with!?


More information about the Commits mailing list