Commit 3b339b2ff82475321e7d732db7c0cd4b3cc185bf

Stefan Sperling 2018-02-12T22:56:07

make struct got_repository opaque

diff --git a/include/got_repository.h b/include/got_repository.h
index 49c27b1..3ca9626 100644
--- a/include/got_repository.h
+++ b/include/got_repository.h
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2017 Stefan Sperling <stsp@openbsd.org>
+ * Copyright (c) 2018 Stefan Sperling <stsp@openbsd.org>
  *
  * Permission to use, copy, modify, and distribute this software for any
  * purpose with or without fee is hereby granted, provided that the above
@@ -14,9 +14,7 @@
  * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
  */
 
-struct got_repository {
-	char *path;
-};
+struct got_repository;
 
 /* Open and close git repositories. */
 const struct got_error *got_repo_open(struct got_repository**, const char *);
diff --git a/lib/repository.c b/lib/repository.c
index 3542514..d6d9843 100644
--- a/lib/repository.c
+++ b/lib/repository.c
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2017 Stefan Sperling <stsp@openbsd.org>
+ * Copyright (c) 2018 Stefan Sperling <stsp@openbsd.org>
  *
  * Permission to use, copy, modify, and distribute this software for any
  * purpose with or without fee is hereby granted, provided that the above
@@ -26,6 +26,10 @@
 
 #include "path.h"
 
+struct got_repository {
+	char *path;
+};
+
 #define GOT_GIT_DIR	".git"
 
 /* Mandatory files and directories inside the git directory. */