summaryrefslogtreecommitdiff
path: root/twofish.c
diff options
context:
space:
mode:
authorNiels Möller <nisse@lysator.liu.se>2001-09-03 00:10:09 +0200
committerNiels Möller <nisse@lysator.liu.se>2001-09-03 00:10:09 +0200
commit346e45c5a71d3c79a0e754987930286d398340fc (patch)
tree793dcdbb52990afc4f93fb2870c2ed457ec961f3 /twofish.c
parentf782075240dfd973b261bc9c6ece3a868eb35321 (diff)
downloadnettle-346e45c5a71d3c79a0e754987930286d398340fc.tar.gz
* twofish.c (twofish_decrypt): Fixed for();-bug in the block-loop.
Spotted by Jean-Pierre. (twofish_encrypt): Likewise. Rev: src/nettle/twofish.c:1.5
Diffstat (limited to 'twofish.c')
-rw-r--r--twofish.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/twofish.c b/twofish.c
index 100a39c7..2a341e84 100644
--- a/twofish.c
+++ b/twofish.c
@@ -337,7 +337,7 @@ twofish_encrypt(struct twofish_ctx *context,
uint32_t (*s_box)[256] = context->s_box;
assert( !(length % TWOFISH_BLOCK_SIZE) );
- for ( ; length; length -= TWOFISH_BLOCK_SIZE);
+ for ( ; length; length -= TWOFISH_BLOCK_SIZE)
{
uint32_t words[4];
uint32_t r0, r1, r2, r3, t0, t1;
@@ -408,7 +408,7 @@ twofish_decrypt(struct twofish_ctx *context,
uint32_t (*s_box)[256] = context->s_box;
assert( !(length % TWOFISH_BLOCK_SIZE) );
- for ( ; length; length -= TWOFISH_BLOCK_SIZE);
+ for ( ; length; length -= TWOFISH_BLOCK_SIZE)
{
uint32_t words[4];
uint32_t r0, r1, r2, r3, t0, t1;