libmcrypt-2.5.8-uninitialized.patch 624 B

12345678910111213
  1. diff -up libmcrypt-2.5.8/modules/algorithms/twofish.c.BAD libmcrypt-2.5.8/modules/algorithms/twofish.c
  2. --- libmcrypt-2.5.8/modules/algorithms/twofish.c.BAD 2008-08-25 17:38:21.000000000 -0400
  3. +++ libmcrypt-2.5.8/modules/algorithms/twofish.c 2008-08-25 17:38:30.000000000 -0400
  4. @@ -499,7 +499,7 @@ static void f_rnd(int i, word32* blk, TW
  5. /* encrypt a block of text */
  6. WIN32DLL_DEFINE void _mcrypt_encrypt(TWI * pkey, word32 * in_blk)
  7. {
  8. - word32 t0, t1, blk[4];
  9. + word32 t0 = 0, t1 = 0, blk[4];
  10. #ifdef WORDS_BIGENDIAN
  11. blk[0] = byteswap32(in_blk[0]) ^ pkey->l_key[0];
  12. blk[1] = byteswap32(in_blk[1]) ^ pkey->l_key[1];