summaryrefslogtreecommitdiff
path: root/hash.h
diff options
context:
space:
mode:
authorLibravatar Junio C Hamano <gitster@pobox.com>2017-07-10 13:42:51 -0700
committerLibravatar Junio C Hamano <gitster@pobox.com>2017-07-10 13:42:51 -0700
commit2db87328ef8246b7dbca90563fecc1e67c6274e6 (patch)
tree8ecbba52925f1095eab841f6d3fc05064d2a7097 /hash.h
parentMerge branch 'rs/free-and-null' (diff)
parentsha1collisiondetection: automatically enable when submodule is populated (diff)
downloadtgif-2db87328ef8246b7dbca90563fecc1e67c6274e6.tar.xz
Merge branch 'ab/sha1dc'
The "collission-detecting" implementation of SHA-1 hash we borrowed from is replaced by directly binding the upstream project as our submodule. Glitches on minority platforms are still being worked out. * ab/sha1dc: sha1collisiondetection: automatically enable when submodule is populated sha1dc: optionally use sha1collisiondetection as a submodule
Diffstat (limited to 'hash.h')
-rw-r--r--hash.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/hash.h b/hash.h
index a11fc9233f..bef3e630a0 100644
--- a/hash.h
+++ b/hash.h
@@ -8,7 +8,11 @@
#elif defined(SHA1_OPENSSL)
#include <openssl/sha.h>
#elif defined(SHA1_DC)
+#ifdef DC_SHA1_SUBMODULE
+#include "sha1collisiondetection/lib/sha1.h"
+#else
#include "sha1dc/sha1.h"
+#endif
#else /* SHA1_BLK */
#include "block-sha1/sha1.h"
#endif