aboutsummaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorGravatar Rob Landley <rob@landley.net>2006-05-16 02:38:26 +0000
committerGravatar Rob Landley <rob@landley.net>2006-05-16 02:38:26 +0000
commit34b5319d86eb639794dcccc56a443e7a35daf5d3 (patch)
treee8a8ee0a912d46c699fab3b5fba67c33fcced333 /include
parentd272dc7cb306995c6a8ec78c13a4aa1021d33a53 (diff)
downloadbusybox-34b5319d86eb639794dcccc56a443e7a35daf5d3.tar.gz
busybox-34b5319d86eb639794dcccc56a443e7a35daf5d3.tar.bz2
Make md5 calculation always go through an the buffer so that A) we don't
handle packets out of sequence if some data goes through the buffer and some doesn't, B) it works on systems that can't handle aligned access, C) we just have one code path to worry about. While we're at it, sizeof() and RESERVE_CONFIG_BUFFER() really don't combine well, which is why md5sum has been reading and processing data 4 bytes at a time. I suspect that the existence of CONFIG_MD5_SIZE_VS_SPEED to do loop unrolling and such in the algorithm was an attempt to work around that bug.
Diffstat (limited to 'include')
-rw-r--r--include/libbb.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/include/libbb.h b/include/libbb.h
index 39361a232..02927cd77 100644
--- a/include/libbb.h
+++ b/include/libbb.h
@@ -506,7 +506,7 @@ typedef struct _md5_ctx_t_ {
uint32_t B;
uint32_t C;
uint32_t D;
- uint32_t total[2];
+ uint64_t total;
uint32_t buflen;
char buffer[128];
} md5_ctx_t;