Mercurial > pidgin.yaz
comparison src/protocols/msn/msg.c @ 10481:bcfea6c3d5c9
[gaim-migrate @ 11769]
Patch 1093958 from Felipe Contreras. It fixes stuff.
I also made some tweaks to make valgrind a bit happier.
committer: Tailor Script <tailor@pidgin.im>
| author | Stu Tomlinson <stu@nosnilmot.com> |
|---|---|
| date | Fri, 07 Jan 2005 02:48:33 +0000 |
| parents | 2e01c503aa4f |
| children | 771c510655c7 |
comparison
equal
deleted
inserted
replaced
| 10480:8e0a91d11362 | 10481:bcfea6c3d5c9 |
|---|---|
| 195 char *end; | 195 char *end; |
| 196 char **elems, **cur, **tokens; | 196 char **elems, **cur, **tokens; |
| 197 | 197 |
| 198 g_return_if_fail(payload != NULL); | 198 g_return_if_fail(payload != NULL); |
| 199 | 199 |
| 200 tmp_base = tmp = g_memdup(payload, payload_len); | 200 tmp_base = tmp = g_malloc0(payload_len + 1); |
| 201 memcpy(tmp_base, payload, payload_len); | |
| 201 | 202 |
| 202 /* Parse the attributes. */ | 203 /* Parse the attributes. */ |
| 203 end = strstr(tmp, "\r\n\r\n"); | 204 end = strstr(tmp, "\r\n\r\n"); |
| 204 /* TODO? some clients use \r delimiters instead of \r\n, the official client | 205 /* TODO? some clients use \r delimiters instead of \r\n, the official client |
| 205 * doesn't send such messages, but does handle receiving them. We'll just | 206 * doesn't send such messages, but does handle receiving them. We'll just |
