From e71edb195539ce8bd2c76cf54048f33a1e6d66be Mon Sep 17 00:00:00 2001 From: rasky Date: Wed, 29 Sep 2010 21:43:06 +0000 Subject: [PATCH] SEC: Add comment to warn about stack overflow. git-svn-id: https://src.develer.com/svnoss/bertos/trunk@4374 38d2e660-2303-0410-9eaa-f027e97ec537 --- bertos/sec/cipher/blowfish_test.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/bertos/sec/cipher/blowfish_test.c b/bertos/sec/cipher/blowfish_test.c index 0a041e62..20b8f66e 100644 --- a/bertos/sec/cipher/blowfish_test.c +++ b/bertos/sec/cipher/blowfish_test.c @@ -166,9 +166,11 @@ int blowfish_testTearDown(void) int blowfish_testRun(void) { + // NOTE: we use a static variable here to avoid stack overflows due to the huge + // context structure of blowfish. static BlowfishContext ctx; blowfish_init(&ctx); - BlockCipher *c = &ctx.c; //blowfish_stackinit(); + BlockCipher *c = &ctx.c; for (int i=0; i