projects
/
mit-scheme.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
a950557
)
Fix buffer overflow in self-test. Derp.
author
Taylor R Campbell
<campbell@mumble.net>
Fri, 11 Jan 2019 09:36:56 +0000
(09:36 +0000)
committer
Taylor R Campbell
<campbell@mumble.net>
Fri, 11 Jan 2019 09:36:56 +0000
(09:36 +0000)
This self-test was not used; there's a separate test in test-md5.scm
which is fine. (The result in this self-test is also correct -- it
just never got tested anywhere.)
src/microcode/md5.c
patch
|
blob
|
history
diff --git
a/src/microcode/md5.c
b/src/microcode/md5.c
index a9a0fe5becbfe9b80f97f5dd5ab73f7168e5de08..c93d6697f4340196405a998b3124fc8379761ab2 100644
(file)
--- a/
src/microcode/md5.c
+++ b/
src/microcode/md5.c
@@
-321,7
+321,7
@@
md5_selftest(void)
md5_init(&m0);
md5_update(&m0, s, i/2);
- md5_update(&m0, s + i/2, i);
+ md5_update(&m0, s + i/2, i
- i/2
);
md5_final(&m0, h);
md5_update(&m, h, 16);
}