pike.git/
src/
post_modules/
Nettle/
hash.cmod
Branch:
Tag:
Non-build tags
All tags
No tags
2015-04-17
2015-04-17 16:00:31 by Martin Nilsson <nilsson@opera.com>
00aadda2972cc4ea07d68985115fbf753fcca436 (
9
lines) (+
5
/-
4
)
[
Show
|
Annotate
]
Branch:
8.1
No need to do init() on the hash context between each use. Digest will drain it.
338:
meta->update(ctx, plen, p); /* 7 */ meta->digest(ctx, dsz, abcbuf); /* 8 */
-
meta->init(ctx);
/* 1 */
+
/* 1 */
meta->update(ctx, plen, p); /* 2 */ meta->update(ctx, slen, s); /* 3 */
358:
meta->digest(ctx, dsz, abcbuf); /* 12 */
-
meta->init(ctx);
/* 13 */
+
/* 13 */
for (i = 0; i < plen; i++) { /* 14 */ meta->update(ctx, plen, p); }
366:
/* Sequence P is implicit. */ /* 16 */
-
meta->init(ctx);
/* 17 */
+
/* 17 */
for(i = 0; i < 16 + abcbuf[0]; i++) { /* 18 */ meta->update(ctx, slen, s); }
375:
/* Sequence S is implicit. */ /* 20 */ for (r = 0; r < rounds; r++) { /* 21 */
-
meta->init(ctx);
/* a */
+
/* a */
if (r & 1) { /* b */ for (i = 0; i + dsz < plen; i += dsz) { meta->update(ctx, dsz, dpbuf);