diff plugins/timestamp.c @ 13104:e1e5462b7d81

[gaim-migrate @ 15466] Rework lots of date parsing. I either introduced a whole lot of bugs, or I've made sure all dates are localized properly now. Only time will tell which it is... ;) committer: Tailor Script <tailor@pidgin.im>
author Richard Laager <rlaager@wiktel.com>
date Thu, 02 Feb 2006 19:50:51 +0000
parents 71299d63801d
children f09c6e8df82c
line wrap: on
line diff
--- a/plugins/timestamp.c	Thu Feb 02 19:39:12 2006 +0000
+++ b/plugins/timestamp.c	Thu Feb 02 19:50:51 2006 +0000
@@ -45,7 +45,7 @@
 	GaimConversation *c = (GaimConversation *)data;
 	GaimGtkConversation *conv = GAIM_GTK_CONVERSATION(c);
 	GtkTextIter iter;
-	char mdate[7];
+	const char *mdate;
 	int is_conversation_active;
 	time_t tim = time(NULL);
 
@@ -63,7 +63,7 @@
 		GtkTextBuffer *buffer = gtk_text_view_get_buffer(GTK_TEXT_VIEW(imhtml));
 		gtk_text_buffer_get_end_iter(buffer, &iter);
 		gaim_conversation_set_data(c, "timestamp-conv-active", GINT_TO_POINTER(FALSE));
-		strftime(mdate, sizeof(mdate), "\n%H:%M", localtime(&tim));
+		mdate = gaim_utf8_strftime("\n%H:%M", localtime(&tim));
 		gtk_text_view_get_visible_rect(GTK_TEXT_VIEW(imhtml), &rect);
 		gtk_text_view_get_line_yrange(GTK_TEXT_VIEW(imhtml), &iter, &y, &height);
 		if(((y + height) - (rect.y + rect.height)) > height