git/list[1] front-page[2] threads[3] people[4] search[5] about
 

[PATCH 04/14] msvc: Fix macro redefinition warnings

From
Ramsay Jones <ramsay@ramsay1.demon.co.uk>
Date
Dec 4, 2010, 19:00 UTC
Message-ID
<4CFA8FE3.1050009@ramsay1.demon.co.uk>

Commit 4091bfc (MinGW: Add missing file mode bit defines, 28-12-2009) causes the msvc build to issue many additional (currently 1008) macro redefinition warnings. The warnings relate to the S_IRUSR, S_IWUSR, S_IXUSR and S_IRWXU macros.

In order to fix the warnings, we simply remove the offending macro definitions which, for both msvc and MinGW, are not required.

Signed-off-by: Ramsay Jones <ramsay@ramsay1.demon.co.uk>
---
 compat/mingw.h |    6 ------
 1 files changed, 0 insertions(+), 6 deletions(-)
diff --git a/compat/mingw.h b/compat/mingw.h
index 99a7467..da316dc 100644
--- a/compat/mingw.h
+++ b/compat/mingw.h
@@ -14,12 +14,6 @@ typedef int socklen_t;
 #define S_ISLNK(x) (((x) & S_IFMT) == S_IFLNK)
 #define S_ISSOCK(x) 0
 
-#ifndef _STAT_H_
-#define S_IRUSR 0
-#define S_IWUSR 0
-#define S_IXUSR 0
-#define S_IRWXU (S_IRUSR | S_IWUSR | S_IXUSR)
-#endif
 #define S_IRGRP 0
 #define S_IWGRP 0
 #define S_IXGRP 0
-- 
1.7.3
Next: Johannes Sixt
Message 1 of 5 in “msvc: Fix macro redefinition warnings”
  1. 04/14 msvc: Fix macro redefinition warningsRamsay Jones, Dec 4, 2010
  2. Johannes SixtDec 4, 2010
  3. Ramsay JonesDec 8, 2010
  4. Sebastian SchuberthDec 8, 2010
  5. Johannes SixtDec 8, 2010

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.