Mercurial > pidgin.yaz
comparison src/protocols/toc/toc.c @ 2343:29449a6b79e6
[gaim-migrate @ 2356]
fix
committer: Tailor Script <tailor@pidgin.im>
author | Eric Warmenhoven <eric@warmenhoven.org> |
---|---|
date | Sat, 22 Sep 2001 02:19:48 +0000 |
parents | b53cd5b63a99 |
children | db02399a9ad7 |
comparison
equal
deleted
inserted
replaced
2342:b1050f14b429 | 2343:29449a6b79e6 |
---|---|
845 } | 845 } |
846 | 846 |
847 static int toc_send_im(struct gaim_connection *gc, char *name, char *message, int flags) | 847 static int toc_send_im(struct gaim_connection *gc, char *name, char *message, int flags) |
848 { | 848 { |
849 char buf[BUF_LEN * 2]; | 849 char buf[BUF_LEN * 2]; |
850 char *tmp = g_malloc(strlen(message) * 2); | 850 char *tmp = g_malloc(strlen(message) * 4 + 1); /* 4 because \n gets replaced with <BR> */ |
851 | 851 |
852 strcpy(tmp, message); | 852 strcpy(tmp, message); |
853 escape_text(tmp); | 853 escape_text(tmp); |
854 if (strlen(tmp) + 52 > MSG_LEN) { | 854 if (strlen(tmp) + 52 > MSG_LEN) { |
855 g_free(tmp); | 855 g_free(tmp); |