[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
CVS gsasl/gl
From: |
gsasl-commit |
Subject: |
CVS gsasl/gl |
Date: |
Tue, 7 Feb 2006 10:21:25 +0100 |
Update of /home/cvs/gsasl/gl
In directory dopio:/tmp/cvs-serv22534/gl
Modified Files:
getaddrinfo.h getopt.c quotearg.c socket_.h stdbool_.h
Log Message:
Update.
--- /home/cvs/gsasl/gl/getaddrinfo.h 2006/01/19 15:45:27 1.12
+++ /home/cvs/gsasl/gl/getaddrinfo.h 2006/02/07 09:21:25 1.13
@@ -71,11 +71,13 @@
# define EAI_OVERFLOW -12 /* Argument buffer overflow. */
#endif
# ifndef EAI_ADDRFAMILY
-/* Not define on mingw32. */
+/* Not defined on mingw32. XXX May be incorrect? Perhaps it is never
+ returned? */
# define EAI_ADDRFAMILY -9 /* Address family for NAME not supported. */
# endif
# ifndef EAI_SYSTEM
-/* Not define on mingw32. */
+/* Not defined on mingw32. XXX May be incorrect? Perhaps it is never
+ returned? */
# define EAI_SYSTEM -11 /* System error returned in `errno'. */
# endif
--- /home/cvs/gsasl/gl/getopt.c 2005/06/15 10:33:56 1.9
+++ /home/cvs/gsasl/gl/getopt.c 2006/02/07 09:21:25 1.10
@@ -2,7 +2,7 @@
NOTE: getopt is now part of the C library, so if you don't know what
"Keep this file name-space clean" means, talk to address@hidden
before changing it!
- Copyright (C) 1987,88,89,90,91,92,93,94,95,96,98,99,2000,2001,2002,2003,2004
+ Copyright (C)
1987,88,89,90,91,92,93,94,95,96,98,99,2000,2001,2002,2003,2004,2006
Free Software Foundation, Inc.
This file is part of the GNU C Library.
@@ -20,28 +20,16 @@
with this program; if not, write to the Free Software Foundation,
Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */
-/* This tells Alpha OSF/1 not to define a getopt prototype in <stdio.h>.
- Ditto for AIX 3.2 and <stdlib.h>. */
-#ifndef _NO_PROTO
-# define _NO_PROTO
-#endif
-
#ifdef HAVE_CONFIG_H
# include <config.h>
#endif
-#include <stdio.h>
-
-/* This needs to come after some library #include
- to get __GNU_LIBRARY__ defined. */
-#ifdef __GNU_LIBRARY__
-/* Don't include stdlib.h for non-GNU C libraries because some of them
- contain conflicting prototypes for getopt. */
-# include <stdlib.h>
-# include <unistd.h>
-#endif /* GNU C library. */
+#include "getopt.h"
+#include <stdio.h>
+#include <stdlib.h>
#include <string.h>
+#include <unistd.h>
#ifdef VMS
# include <unixlib.h>
@@ -76,7 +64,6 @@
GNU application programs can use a third alternative mode in which
they can distinguish the relative order of options and other arguments. */
-#include "getopt.h"
#include "getopt_int.h"
/* For communication from `getopt' to the caller.
@@ -118,16 +105,9 @@
static struct _getopt_data getopt_data;
-#ifndef __GNU_LIBRARY__
-
-/* Avoid depending on library functions or files
- whose names are inconsistent. */
-
-#ifndef getenv
+#if defined HAVE_DECL_GETENV && !HAVE_DECL_GETENV
extern char *getenv ();
#endif
-
-#endif /* not __GNU_LIBRARY__ */
#ifdef _LIBC
/* Stored original parameters.
@@ -556,10 +536,7 @@
int old_flags2 = ((_IO_FILE *) stderr)->_flags2;
((_IO_FILE *) stderr)->_flags2 |= _IO_FLAGS2_NOTCANCEL;
- if (_IO_fwide (stderr, 0) > 0)
- __fwprintf (stderr, L"%s", buf);
- else
- fputs (buf, stderr);
+ __fxprintf (NULL, "%s", buf);
((_IO_FILE *) stderr)->_flags2 = old_flags2;
_IO_funlockfile (stderr);
@@ -634,10 +611,7 @@
((_IO_FILE *) stderr)->_flags2
|= _IO_FLAGS2_NOTCANCEL;
- if (_IO_fwide (stderr, 0) > 0)
- __fwprintf (stderr, L"%s", buf);
- else
- fputs (buf, stderr);
+ __fxprintf (NULL, "%s", buf);
((_IO_FILE *) stderr)->_flags2 = old_flags2;
_IO_funlockfile (stderr);
@@ -674,10 +648,7 @@
((_IO_FILE *) stderr)->_flags2
|= _IO_FLAGS2_NOTCANCEL;
- if (_IO_fwide (stderr, 0) > 0)
- __fwprintf (stderr, L"%s", buf);
- else
- fputs (buf, stderr);
+ __fxprintf (NULL, "%s", buf);
((_IO_FILE *) stderr)->_flags2 = old_flags2;
_IO_funlockfile (stderr);
@@ -751,10 +722,7 @@
int old_flags2 = ((_IO_FILE *) stderr)->_flags2;
((_IO_FILE *) stderr)->_flags2 |= _IO_FLAGS2_NOTCANCEL;
- if (_IO_fwide (stderr, 0) > 0)
- __fwprintf (stderr, L"%s", buf);
- else
- fputs (buf, stderr);
+ __fxprintf (NULL, "%s", buf);
((_IO_FILE *) stderr)->_flags2 = old_flags2;
_IO_funlockfile (stderr);
@@ -817,10 +785,7 @@
int old_flags2 = ((_IO_FILE *) stderr)->_flags2;
((_IO_FILE *) stderr)->_flags2 |= _IO_FLAGS2_NOTCANCEL;
- if (_IO_fwide (stderr, 0) > 0)
- __fwprintf (stderr, L"%s", buf);
- else
- fputs (buf, stderr);
+ __fxprintf (NULL, "%s", buf);
((_IO_FILE *) stderr)->_flags2 = old_flags2;
_IO_funlockfile (stderr);
@@ -868,10 +833,7 @@
int old_flags2 = ((_IO_FILE *) stderr)->_flags2;
((_IO_FILE *) stderr)->_flags2 |= _IO_FLAGS2_NOTCANCEL;
- if (_IO_fwide (stderr, 0) > 0)
- __fwprintf (stderr, L"%s", buf);
- else
- fputs (buf, stderr);
+ __fxprintf (NULL, "%s", buf);
((_IO_FILE *) stderr)->_flags2 = old_flags2;
_IO_funlockfile (stderr);
@@ -940,10 +902,7 @@
int old_flags2 = ((_IO_FILE *) stderr)->_flags2;
((_IO_FILE *) stderr)->_flags2 |= _IO_FLAGS2_NOTCANCEL;
- if (_IO_fwide (stderr, 0) > 0)
- __fwprintf (stderr, L"%s", buf);
- else
- fputs (buf, stderr);
+ __fxprintf (NULL, "%s", buf);
((_IO_FILE *) stderr)->_flags2 = old_flags2;
_IO_funlockfile (stderr);
@@ -985,10 +944,7 @@
((_IO_FILE *) stderr)->_flags2
|= _IO_FLAGS2_NOTCANCEL;
- if (_IO_fwide (stderr, 0) > 0)
- __fwprintf (stderr, L"%s", buf);
- else
- fputs (buf, stderr);
+ __fxprintf (NULL, "%s", buf);
((_IO_FILE *) stderr)->_flags2 = old_flags2;
_IO_funlockfile (stderr);
@@ -1027,10 +983,7 @@
((_IO_FILE *) stderr)->_flags2
|= _IO_FLAGS2_NOTCANCEL;
- if (_IO_fwide (stderr, 0) > 0)
- __fwprintf (stderr, L"%s", buf);
- else
- fputs (buf, stderr);
+ __fxprintf (NULL, "%s", buf);
((_IO_FILE *) stderr)->_flags2 = old_flags2;
_IO_funlockfile (stderr);
@@ -1101,10 +1054,7 @@
int old_flags2 = ((_IO_FILE *) stderr)->_flags2;
((_IO_FILE *) stderr)->_flags2 |= _IO_FLAGS2_NOTCANCEL;
- if (_IO_fwide (stderr, 0) > 0)
- __fwprintf (stderr, L"%s", buf);
- else
- fputs (buf, stderr);
+ __fxprintf (NULL, "%s", buf);
((_IO_FILE *) stderr)->_flags2 = old_flags2;
_IO_funlockfile (stderr);
--- /home/cvs/gsasl/gl/quotearg.c 2005/09/25 10:23:41 1.3
+++ /home/cvs/gsasl/gl/quotearg.c 2006/02/07 09:21:25 1.4
@@ -1,7 +1,7 @@
/* quotearg.c - quote arguments for output
- Copyright (C) 1998, 1999, 2000, 2001, 2002, 2004, 2005 Free Software
- Foundation, Inc.
+ Copyright (C) 1998, 1999, 2000, 2001, 2002, 2004, 2005, 2006 Free
+ Software Foundation, Inc.
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
@@ -307,6 +307,9 @@
STORE ('\\');
STORE ('?');
break;
+
+ default:
+ break;
}
break;
@@ -454,6 +457,9 @@
case '[': case '\\': case '^':
case '`': case '|':
goto use_shell_always_quoting_style;
+
+ default:
+ break;
}
}
--- /home/cvs/gsasl/gl/socket_.h 2006/01/19 15:45:27 1.4
+++ /home/cvs/gsasl/gl/socket_.h 2006/02/07 09:21:25 1.5
@@ -27,8 +27,23 @@
winsock2.h and ws2tcpip.h that declare the sys/socket.h definitions
we need. */
-#define WINVER 0x0501
#if HAVE_WINSOCK2_H
+/* The following define makes sure we get all the prototypes from the
+ header files. getaddrinfo is only available if _WIN32_WINNT >=
+ 0x0501 (that symbol is set indiriectly through WINVER). This has
+ the following two (potential) problems:
+
+ 1) winsock2.h must not have been included before this symbol
+ is set (I think).
+
+ 2) There may be some _reason_ for all prototypes not being
+ available with the default settings. Such as if some APIs are
+ not available on older Windows hosts. However, getaddrinfo
+ (which need >= 0x0501) should be available on Windows 95 and
+ later, according to:
+
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/winsock/winsock/getaddrinfo_2.asp
+*/
+#define WINVER 0x0501
# include <winsock2.h>
#endif
#if HAVE_WS2TCPIP_H
@@ -36,14 +51,14 @@
#endif
/* For shutdown(). */
-#if !defined(SHUT_RD) && defined (SD_RECEIVE)
+#if !defined SHUT_RD && defined SD_RECEIVE
# define SHUT_RD SD_RECEIVE
#endif
-#if !defined(SHUT_WR) && defined (SD_SEND)
-# define SHUT_WR 1
+#if !defined SHUT_WR && defined SD_SEND
+# define SHUT_WR SD_SEND
#endif
-#if !defined(SHUT_RDWR) && defined (SD_BOTH)
-# define SHUT_RDWR 2
+#if !defined SHUT_RDWR && defined SD_BOTH
+# define SHUT_RDWR SD_BOTH
#endif
#endif /* _SYS_SOCKET_H */
--- /home/cvs/gsasl/gl/stdbool_.h 2005/06/15 10:33:56 1.6
+++ /home/cvs/gsasl/gl/stdbool_.h 2006/02/07 09:21:25 1.7
@@ -1,4 +1,4 @@
-/* Copyright (C) 2001, 2002, 2003 Free Software Foundation, Inc.
+/* Copyright (C) 2001, 2002, 2003, 2006 Free Software Foundation, Inc.
Written by Bruno Haible <address@hidden>, 2001.
This program is free software; you can redistribute it and/or modify
@@ -70,18 +70,40 @@
(see ISO C 99 6.7.2.2.(4)); however, '_Bool' must promote to 'int'
(see ISO C 99 6.3.1.1.(2)). So we add a negative value to the
enum; this ensures that '_Bool' promotes to 'int'. */
-#if !(defined __cplusplus || defined __BEOS__)
+#if defined __cplusplus || defined __BEOS__
+ /* A compiler known to have 'bool'. */
+ /* If the compiler already has both 'bool' and '_Bool', we can assume they
+ are the same types. */
# if address@hidden@
-# if defined __SUNPRO_C && (__SUNPRO_C < 0x550 || __STDC__ == 1)
- /* Avoid stupid "warning: _Bool is a keyword in ISO C99". */
-# define _Bool signed char
+typedef bool _Bool;
+# endif
+#else
+# if !defined __GNUC__
+ /* If @HAVE__BOOL@:
+ Some HP-UX cc and AIX IBM C compiler versions have compiler bugs when
+ the built-in _Bool type is used. See
+ http://gcc.gnu.org/ml/gcc-patches/2003-12/msg02303.html
+ http://lists.gnu.org/archive/html/bug-coreutils/2005-11/msg00161.html
+ http://lists.gnu.org/archive/html/bug-coreutils/2005-10/msg00086.html
+ Similar bugs are likely with other compilers as well; this file
+ wouldn't be used if <stdbool.h> was working.
+ So we override the _Bool type.
+ If address@hidden@:
+ Need to define _Bool ourselves. As 'signed char' or as an enum type?
+ Use of a typedef, with SunPRO C, leads to a stupid
+ "warning: _Bool is a keyword in ISO C99".
+ Use of an enum type, with IRIX cc, leads to a stupid
+ "warning(1185): enumerated type mixed with another type".
+ The only benefit of the enum type, debuggability, is not important
+ with these compilers. So use 'signed char' and no typedef. */
+# define _Bool signed char
enum { false = 0, true = 1 };
-# else
+# else
+ /* With this compiler, trust the _Bool type if the compiler has it. */
+# if address@hidden@
typedef enum { _Bool_must_promote_to_int = -1, false = 0, true = 1 } _Bool;
# endif
# endif
-#else
-typedef bool _Bool;
#endif
#define bool _Bool
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- CVS gsasl/gl,
gsasl-commit <=