Commit 6e6ec54bebb41fd0c0f1171b04d13306937b9636

Carlos Martín Nieto 2011-08-06T11:26:59

Force the test's main function to use cdecl under Windows Signed-off-by: Carlos Martín Nieto <carlos@cmartin.tk>

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
diff --git a/tests/test_main.c b/tests/test_main.c
index 1a35e60..c9f8da3 100644
--- a/tests/test_main.c
+++ b/tests/test_main.c
@@ -69,7 +69,12 @@ static libgit2_suite suite_methods[]= {
 
 #define GIT_SUITE_COUNT (ARRAY_SIZE(suite_methods))
 
-int main(int GIT_UNUSED(argc), char *GIT_UNUSED(argv[]))
+#ifdef GIT_WIN32
+int __cdecl
+#else
+int
+#endif
+main(int GIT_UNUSED(argc), char *GIT_UNUSED(argv[]))
 {
 	unsigned int i, failures;