Merge pull request #2139 from ethomson/va_copy_warning Include stdarg.h for the va_copy test
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139
diff --git a/src/buffer.c b/src/buffer.c
index 318fee7..a83ca87 100644
--- a/src/buffer.c
+++ b/src/buffer.c
@@ -7,7 +7,6 @@
#include "buffer.h"
#include "posix.h"
#include "git2/buffer.h"
-#include <stdarg.h>
#include <ctype.h>
/* Used as default value for git_buf->ptr so that people can always
diff --git a/src/buffer.h b/src/buffer.h
index 564a4f5..4c852b3 100644
--- a/src/buffer.h
+++ b/src/buffer.h
@@ -7,8 +7,6 @@
#ifndef INCLUDE_buffer_h__
#define INCLUDE_buffer_h__
-#include <stdarg.h>
-
#include "common.h"
#include "git2/strarray.h"
#include "git2/buffer.h"
diff --git a/src/cc-compat.h b/src/cc-compat.h
index 37f1ea8..e73cb6d 100644
--- a/src/cc-compat.h
+++ b/src/cc-compat.h
@@ -7,6 +7,8 @@
#ifndef INCLUDE_compat_h__
#define INCLUDE_compat_h__
+#include <stdarg.h>
+
/*
* See if our compiler is known to support flexible array members.
*/
diff --git a/src/commit.c b/src/commit.c
index de50e77..2f5a5b5 100644
--- a/src/commit.c
+++ b/src/commit.c
@@ -17,8 +17,6 @@
#include "signature.h"
#include "message.h"
-#include <stdarg.h>
-
void git_commit__free(void *_commit)
{
git_commit *commit = _commit;
diff --git a/src/errors.c b/src/errors.c
index a0b0859..393a787 100644
--- a/src/errors.c
+++ b/src/errors.c
@@ -8,7 +8,6 @@
#include "global.h"
#include "posix.h"
#include "buffer.h"
-#include <stdarg.h>
/********************************************
* New error handling
diff --git a/src/filebuf.c b/src/filebuf.c
index 9c3dae8..d23bcc1 100644
--- a/src/filebuf.c
+++ b/src/filebuf.c
@@ -4,8 +4,6 @@
* This file is part of libgit2, distributed under the GNU GPL v2 with
* a Linking Exception. For full terms see the included COPYING file.
*/
-#include <stdarg.h>
-
#include "common.h"
#include "filebuf.h"
#include "fileops.h"
diff --git a/src/object.c b/src/object.c
index 3fc984b..40cae18 100644
--- a/src/object.c
+++ b/src/object.c
@@ -4,8 +4,6 @@
* This file is part of libgit2, distributed under the GNU GPL v2 with
* a Linking Exception. For full terms see the included COPYING file.
*/
-#include <stdarg.h>
-
#include "git2/object.h"
#include "common.h"
diff --git a/src/path.c b/src/path.c
index feb2739..89409ea 100644
--- a/src/path.c
+++ b/src/path.c
@@ -12,7 +12,6 @@
#else
#include <dirent.h>
#endif
-#include <stdarg.h>
#include <stdio.h>
#include <ctype.h>
diff --git a/src/repository.c b/src/repository.c
index 96ed306..8b336c2 100644
--- a/src/repository.c
+++ b/src/repository.c
@@ -4,7 +4,6 @@
* This file is part of libgit2, distributed under the GNU GPL v2 with
* a Linking Exception. For full terms see the included COPYING file.
*/
-#include <stdarg.h>
#include <ctype.h>
#include "git2/object.h"
diff --git a/src/settings.c b/src/settings.c
index 748f765..7c2a303 100644
--- a/src/settings.c
+++ b/src/settings.c
@@ -5,8 +5,6 @@
* a Linking Exception. For full terms see the included COPYING file.
*/
-#include <stdarg.h>
-
#include <git2.h>
#include "common.h"
#include "fileops.h"
diff --git a/src/trace.h b/src/trace.h
index 77b1e03..4d4e3bf 100644
--- a/src/trace.h
+++ b/src/trace.h
@@ -7,8 +7,6 @@
#ifndef INCLUDE_trace_h__
#define INCLUDE_trace_h__
-#include <stdarg.h>
-
#include <git2/trace.h>
#include "buffer.h"