Mercurial > pidgin
changeset 26867:4f36ec04181c
merge of '2b7afd5f3a168b013e5d3cd69999ffb6e0ee95a6'
and '2c9a1153bc1694e9656752a73526bd6b7461265b'
author | Ka-Hing Cheung <khc@hxbc.us> |
---|---|
date | Mon, 11 May 2009 01:37:56 +0000 |
parents | 0402ec1872dc (current diff) ccc217362818 (diff) |
children | 329f5a43b68a |
files | |
diffstat | 1 files changed, 5 insertions(+), 3 deletions(-) [+] |
line wrap: on
line diff
--- a/libpurple/protocols/qq/qq_crypt.c Sun May 10 23:41:06 2009 +0000 +++ b/libpurple/protocols/qq/qq_crypt.c Mon May 11 01:37:56 2009 +0000 @@ -163,9 +163,11 @@ c32_prev[0] = crypted32[0]; c32_prev[1] = crypted32[1]; /* set next 64 bits want to crypt*/ - crypted_ptr += 8; - memcpy(crypted32, crypted_ptr, sizeof(crypted32)); - plain32[0] = crypted32[0] ^ c32_prev[0]; plain32[1] = crypted32[1] ^ c32_prev[1]; + if (count64 > 0) { + crypted_ptr += 8; + memcpy(crypted32, crypted_ptr, sizeof(crypted32)); + plain32[0] = crypted32[0] ^ c32_prev[0]; plain32[1] = crypted32[1] ^ c32_prev[1]; + } } }