[PATCH 09/14] Avoid including windows.h in winansi.c for MSVC build

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



From: Frank Li <lznuaa@xxxxxxxxx>

compat/msvc.h includes winsock2.h which conflicts with windows.h.
msvc.h also defines the oldest Windows API version required.

Signed-off-by: Frank Li <lznuaa@xxxxxxxxx>
Signed-off-by: Marius Storm-Olsen <mstormo@xxxxxxxxx>
---
 compat/winansi.c |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/compat/winansi.c b/compat/winansi.c
index 9217c24..0d79845 100644
--- a/compat/winansi.c
+++ b/compat/winansi.c
@@ -2,7 +2,9 @@
  * Copyright 2008 Peter Harris <git@xxxxxxxxxxxxxxxxxxx>
  */
 
+#ifndef _MSC_VER
 #include <windows.h>
+#endif
 #include "../git-compat-util.h"
 
 /*
-- 
1.6.3.msysgit.0.18.gef407

--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]