diff libpurple/protocols/yahoo/yahoo_filexfer.c @ 32246:f70353405940

Fix truncation of a string in the Yahoo! prpl to be not quite so stupid.
author Ethan Blanton <elb@pidgin.im>
date Thu, 11 Aug 2011 16:30:51 +0000
parents b671728e6ee9
children 9aee8493db7f dc4de0b08405
line wrap: on
line diff
--- a/libpurple/protocols/yahoo/yahoo_filexfer.c	Thu Aug 11 16:24:26 2011 +0000
+++ b/libpurple/protocols/yahoo/yahoo_filexfer.c	Thu Aug 11 16:30:51 2011 +0000
@@ -1428,7 +1428,7 @@
 
 	unix_time = time(NULL);
 	time_str = ctime(&unix_time);
-	strcpy(time_str + strlen(time_str) - 1, "\0");
+	time_str[strlen(time_str) - 1] = '\0';
 
 	if (xd->txbuflen == 0)	{
 		xd->txbuf = g_strdup_printf("HTTP/1.0 200 OK\r\n"