Browse Source

feat: add 32-bit architecture supoort

master
Dnomd343 1 week ago
parent
commit
71de63c6f4
  1. 3
      src/md5.h
  2. 2
      test/stream.cc

3
src/md5.h

@ -4,9 +4,6 @@
#include <string>
#include <cstdint>
static_assert(sizeof(uintptr_t) == 8,
"Project only works on 64-bits architecture.");
#ifdef _MSC_VER
static_assert('\x01\x02\x03\x04' == 0x04030201,
#else

2
test/stream.cc

@ -8,7 +8,7 @@ TEST(md5sum, stream) {
const auto test_data = build_test_data(256 * 256);
MD5 md5;
for (uint64_t size = 1; size <= 256; ++size) {
for (uint32_t size = 1; size <= 256; ++size) {
auto expect = MD5::Hash(test_data.data(), size * 256);
for (int times = 0; times < 256; ++times) {

Loading…
Cancel
Save