Commit 6e1efcd66934bd6c5946af01a6d5b1b83b84ddb8

Patrick Steinhardt 2020-06-08T12:46:04

tree-wide: add missing header includes We're missing some header includes leading to missing function prototypes. While we currently don't warn about these, we should have their respective headers included in order to detect the case where a function signature change results in an incompatibility.

diff --git a/src/config_snapshot.c b/src/config_snapshot.c
index 62b9068..e295d2f 100644
--- a/src/config_snapshot.c
+++ b/src/config_snapshot.c
@@ -5,8 +5,9 @@
  * a Linking Exception. For full terms see the included COPYING file.
  */
 
-#include "config.h"
+#include "config_backend.h"
 
+#include "config.h"
 #include "config_entries.h"
 
 typedef struct {
diff --git a/src/reflog.c b/src/reflog.c
index 33b7310..34537aa 100644
--- a/src/reflog.c
+++ b/src/reflog.c
@@ -12,7 +12,8 @@
 #include "signature.h"
 #include "refdb.h"
 
-#include <git2/sys/refdb_backend.h>
+#include "git2/sys/refdb_backend.h"
+#include "git2/sys/reflog.h"
 
 void git_reflog_entry__free(git_reflog_entry *entry)
 {
diff --git a/src/streams/registry.c b/src/streams/registry.c
index 3300320..a5fa849 100644
--- a/src/streams/registry.c
+++ b/src/streams/registry.c
@@ -5,9 +5,10 @@
  * a Linking Exception. For full terms see the included COPYING file.
  */
 
-#include "git2/errors.h"
-
 #include "common.h"
+
+#include "streams/registry.h"
+
 #include "global.h"
 #include "streams/tls.h"
 #include "streams/mbedtls.h"