]> git.ipfire.org Git - thirdparty/git.git/commitdiff
base85.h: move declarations for base85.c functions from cache.h
authorElijah Newren <newren@gmail.com>
Sat, 22 Apr 2023 20:17:13 +0000 (20:17 +0000)
committerJunio C Hamano <gitster@pobox.com>
Mon, 24 Apr 2023 19:47:32 +0000 (12:47 -0700)
Signed-off-by: Elijah Newren <newren@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
apply.c
base85.c
base85.h [new file with mode: 0644]
cache.h
diff.c

diff --git a/apply.c b/apply.c
index efe2dcb0e62ec7ef2b34075a0faa20f01883c296..a65a354eef5e869ab3c8adbb17dc4c58744a40a5 100644 (file)
--- a/apply.c
+++ b/apply.c
@@ -10,6 +10,7 @@
 #include "cache.h"
 #include "abspath.h"
 #include "alloc.h"
+#include "base85.h"
 #include "config.h"
 #include "object-store.h"
 #include "blob.h"
index 5ca601ee14fd2ab3b78577aa22a5db778bc7fbe0..bbacdca31b3bc3c1020d49e8e0c4c539a1232cbc 100644 (file)
--- a/base85.c
+++ b/base85.c
@@ -1,4 +1,5 @@
-#include "cache.h"
+#include "git-compat-util.h"
+#include "base85.h"
 
 #undef DEBUG_85
 
diff --git a/base85.h b/base85.h
new file mode 100644 (file)
index 0000000..c835086
--- /dev/null
+++ b/base85.h
@@ -0,0 +1,7 @@
+#ifndef BASE85_H
+#define BASE85_H
+
+int decode_85(char *dst, const char *line, int linelen);
+void encode_85(char *buf, const unsigned char *data, int bytes);
+
+#endif /* BASE85_H */
diff --git a/cache.h b/cache.h
index 2b6617647945e1c6663063253b9783936090535f..b89f4c598025f64f428933c15a04c192f25ca681 100644 (file)
--- a/cache.h
+++ b/cache.h
@@ -593,10 +593,6 @@ int df_name_compare(const char *name1, size_t len1, int mode1,
 int name_compare(const char *name1, size_t len1, const char *name2, size_t len2);
 int cache_name_stage_compare(const char *name1, int len1, int stage1, const char *name2, int len2, int stage2);
 
-/* base85 */
-int decode_85(char *dst, const char *line, int linelen);
-void encode_85(char *buf, const unsigned char *data, int bytes);
-
 /* pkt-line.c */
 void packet_trace_identity(const char *prog);
 
diff --git a/diff.c b/diff.c
index fa86d023196b8a95f9f413f96b7bd2586b47add9..e697f78a645992b00aa403acbc6fc554769e2a26 100644 (file)
--- a/diff.c
+++ b/diff.c
@@ -4,6 +4,7 @@
 #include "cache.h"
 #include "abspath.h"
 #include "alloc.h"
+#include "base85.h"
 #include "config.h"
 #include "convert.h"
 #include "environment.h"