Project

General

Profile

Cosmetic #254 » 0001-Fix-GCC-warnings.patch

Patch against latest HEAD - Arnaud Fontaine, 2011-10-04 07:40

View differences:

configure.ac
AC_TYPE_UINT32_T
AC_TYPE_UINT8_T
AX_C___ATTRIBUTE__
AH_BOTTOM([
/* Unused attributes such as function parameters (GCC extension) */
#ifdef HAVE___ATTRIBUTE__
# define UNUSED(ATTRIBUTE) ATTRIBUTE __attribute__((unused))
#else
# define UNUSED(ATTRIBUTE) ATTRIBUTE
#endif])
# Checks for library functions.
AC_FUNC_FORK
AC_FUNC_MALLOC
src/config.h.in
/* Define to 1 if `vfork' works. */
#undef HAVE_WORKING_VFORK
/* define if your compiler has __attribute__ */
#undef HAVE___ATTRIBUTE__
/* Define to 1 if your C compiler doesn't accept -c and -o together. */
#undef NO_MINUS_C_MINUS_O
......
/* Define as `fork' if `vfork' does not work. */
#undef vfork
/* Unused attributes such as function parameters (GCC extension) */
#ifdef HAVE___ATTRIBUTE__
# define UNUSED(ATTRIBUTE) ATTRIBUTE __attribute__((unused))
#else
# define UNUSED(ATTRIBUTE) ATTRIBUTE
#endif
src/connection.c
}
/* ripped from postfix's tls_dh.c */
static DH *tmp_dh_cb(SSL *ssl_unused __attribute__((unused)),
int export, int keylength)
static DH *tmp_dh_cb(UNUSED(SSL *ssl_unused), int export, int keylength)
{
DH *ret;
src/irc.c
return OK_COPY_WHO;
}
static int irc_315(struct link_server *server,
struct line *l __attribute__((unused)))
static int irc_315(struct link_server *server, UNUSED(struct line *l))
{
struct link *link = LINK(server);
if (link->who_client) {
......
}
/* same as irc_315 */
static int irc_368(struct link_server *server,
struct line *l __attribute__((unused)))
static int irc_368(struct link_server *server, UNUSED(struct line *l))
{
struct link *link = LINK(server);
if (link->who_client) {
(2-2/2)