summaryrefslogtreecommitdiffstats
path: root/sha1dc/sha1.c
diff options
context:
space:
mode:
authorJeff King <peff@peff.net>2017-03-16 23:08:10 +0100
committerJunio C Hamano <gitster@pobox.com>2017-03-16 23:16:45 +0100
commit45a574eec82424ac11c4c5fe117725597309b9c9 (patch)
treea3e7618713df7cab69d1be29d9a89c59ee0afefd /sha1dc/sha1.c
parentsha1dc: add collision-detecting sha1 implementation (diff)
downloadgit-45a574eec82424ac11c4c5fe117725597309b9c9.tar.xz
git-45a574eec82424ac11c4c5fe117725597309b9c9.zip
sha1dc: adjust header includes for git
We can replace system includes with git-compat-util.h or cache.h (and should make sure it is included first in all C files). And we can drop includes from headers entirely, as every C file should include git-compat-util.h itself. We will add in new include guards around the header files, though (otherwise you get into trouble including both sha1dc/sha1.h and cache.h). And finally, we'll use the full "sha1dc/" path for including related files. This isn't strictly necessary, but makes the expected resolution more obvious. Signed-off-by: Jeff King <peff@peff.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'sha1dc/sha1.c')
-rw-r--r--sha1dc/sha1.c10
1 files changed, 3 insertions, 7 deletions
diff --git a/sha1dc/sha1.c b/sha1dc/sha1.c
index 27a535c6a7..d25d93abd8 100644
--- a/sha1dc/sha1.c
+++ b/sha1dc/sha1.c
@@ -5,13 +5,9 @@
* https://opensource.org/licenses/MIT
***/
-#include <string.h>
-#include <memory.h>
-#include <stdio.h>
-#include <stdlib.h>
-
-#include "sha1.h"
-#include "ubc_check.h"
+#include "cache.h"
+#include "sha1dc/sha1.h"
+#include "sha1dc/ubc_check.h"
/*