Mercurial > pidgin.yaz
changeset 31643:8a15b164ef30
Fix a potential information leak in cipher.c.
committer: John Bailey <rekkanoryo@rekkanoryo.org>
author | julia@diku.dk |
---|---|
date | Fri, 04 Feb 2011 01:38:51 +0000 |
parents | b935d9f5cc68 |
children | c2c3200f48ab |
files | libpurple/cipher.c |
diffstat | 1 files changed, 6 insertions(+), 6 deletions(-) [+] |
line wrap: on
line diff
--- a/libpurple/cipher.c Thu Feb 03 04:38:19 2011 +0000 +++ b/libpurple/cipher.c Fri Feb 04 01:38:51 2011 +0000 @@ -249,7 +249,7 @@ purple_cipher_context_reset(context, NULL); md5_context = purple_cipher_context_get_data(context); - memset(md5_context, 0, sizeof(md5_context)); + memset(md5_context, 0, sizeof(*md5_context)); g_free(md5_context); md5_context = NULL; @@ -705,7 +705,7 @@ purple_cipher_context_reset(context, NULL); md4_context = purple_cipher_context_get_data(context); - memset(md4_context, 0, sizeof(md4_context)); + memset(md4_context, 0, sizeof(*md4_context)); g_free(md4_context); md4_context = NULL; @@ -1356,7 +1356,7 @@ struct _des_ctx *des_context; des_context = purple_cipher_context_get_data(context); - memset(des_context, 0, sizeof(des_context)); + memset(des_context, 0, sizeof(*des_context)); g_free(des_context); des_context = NULL; @@ -1706,7 +1706,7 @@ struct _des3_ctx *des3_context; des3_context = purple_cipher_context_get_data(context); - memset(des3_context, 0, sizeof(des3_context)); + memset(des3_context, 0, sizeof(*des3_context)); g_free(des3_context); des3_context = NULL; @@ -2382,7 +2382,7 @@ struct RC4Context *rc4_ctx; rc4_ctx = purple_cipher_context_get_data(context); - memset(rc4_ctx, 0, sizeof(rc4_ctx)); + memset(rc4_ctx, 0, sizeof(*rc4_ctx)); g_free(rc4_ctx); rc4_ctx = NULL; @@ -2828,7 +2828,7 @@ if(cipher->ops && cipher->ops->uninit) cipher->ops->uninit(context); - memset(context, 0, sizeof(context)); + memset(context, 0, sizeof(*context)); g_free(context); context = NULL; }