comparison libpurple/protocols/msn/msg.c @ 29274:e0e0cecdcd16

propagate from branch 'im.pidgin.pidgin' (head 53ec2e73334e6dc99c29f0f13b5ebf4700f5a92c) to branch 'im.pidgin.cpw.attention_ui' (head 2ce3177a8ec94edba0f242ea181a9bd0f2655751)
author Marcus Lundblad <ml@update.uu.se>
date Tue, 24 Feb 2009 20:26:34 +0000
parents 4460eab56456 15fc25014ce2
children e57315a062cb
comparison
equal deleted inserted replaced
29273:4460eab56456 29274:e0e0cecdcd16
350 g_free(msg->body); 350 g_free(msg->body);
351 msg->body = g_malloc(msg->body_len + 1); 351 msg->body = g_malloc(msg->body_len + 1);
352 memcpy(msg->body, tmp, msg->body_len); 352 memcpy(msg->body, tmp, msg->body_len);
353 msg->body[msg->body_len] = '\0'; 353 msg->body[msg->body_len] = '\0';
354 } 354 }
355
356 if (msg->charset == NULL) {
357 char *body = g_convert(msg->body, msg->body_len, "UTF-8",
358 "ISO-8859-1", NULL, &msg->body_len, NULL);
359 g_free(msg->body);
360 msg->body = body;
361 msg->charset = g_strdup("UTF-8");
362 }
355 } 363 }
356 364
357 g_free(tmp_base); 365 g_free(tmp_base);
358 } 366 }
359 367