diff options
author | Magnus Hagander <magnus@hagander.net> | 2010-02-09 19:55:14 +0000 |
---|---|---|
committer | Magnus Hagander <magnus@hagander.net> | 2010-02-09 19:55:14 +0000 |
commit | a8d3a395aafd3255be7603f6bf33d2f8a7eb7f25 (patch) | |
tree | 4ce25061be64d34eb73999973f45823c71805e01 /src | |
parent | 8740fe7136f4552e609ccf8b0b26ed77e4351311 (diff) | |
download | postgresql-a8d3a395aafd3255be7603f6bf33d2f8a7eb7f25.tar.gz postgresql-a8d3a395aafd3255be7603f6bf33d2f8a7eb7f25.zip |
Define the value for in6addr_any on MingW, since it provides the struct
only in the header files and not in any libraries, yet declare it as
an extern.
Diffstat (limited to 'src')
-rw-r--r-- | src/backend/port/win32/mingwcompat.c | 13 |
1 files changed, 10 insertions, 3 deletions
diff --git a/src/backend/port/win32/mingwcompat.c b/src/backend/port/win32/mingwcompat.c index 19fed37a659..ca7541ab1ff 100644 --- a/src/backend/port/win32/mingwcompat.c +++ b/src/backend/port/win32/mingwcompat.c @@ -6,20 +6,27 @@ * Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group * * IDENTIFICATION - * $PostgreSQL: pgsql/src/backend/port/win32/mingwcompat.c,v 1.8 2010/01/02 16:57:50 momjian Exp $ + * $PostgreSQL: pgsql/src/backend/port/win32/mingwcompat.c,v 1.9 2010/02/09 19:55:14 mha Exp $ * *------------------------------------------------------------------------- */ #include "postgres.h" +#ifndef WIN32_ONLY_COMPILER +/* + * MingW defines an extern to this struct, but the actual struct isn't present + * in any library. It's trivial enough that we can safely defined it + * ourselves. + */ +const struct in6_addr in6addr_any = {{{0,0,0,0, 0,0,0,0, 0,0,0,0, 0,0,0,0}}}; + + /* * This file contains loaders for functions that are missing in the MinGW * import libraries. It's only for actual Win32 API functions, so they are * all present in proper Win32 compilers. */ -#ifndef WIN32_ONLY_COMPILER - static HMODULE kernel32 = NULL; /* |