version 1.1, 2012/02/21 22:30:18
|
version 1.1.1.1, 2012/10/09 09:06:54
|
Line 4
|
Line 4
|
|
|
/* |
/* |
* Copyright (c) 1995 RadioMail Corporation. All rights reserved. |
* Copyright (c) 1995 RadioMail Corporation. All rights reserved. |
* Copyright (c) 2011 by Internet Systems Consortium, Inc. ("ISC") | * Copyright (c) 2011,2012 by Internet Systems Consortium, Inc. ("ISC") |
* Copyright (c) 2004,2009 by Internet Systems Consortium, Inc. ("ISC") |
* Copyright (c) 2004,2009 by Internet Systems Consortium, Inc. ("ISC") |
* Copyright (c) 1996-2003 by Internet Software Consortium |
* Copyright (c) 1996-2003 by Internet Software Consortium |
* |
* |
Line 46
|
Line 46
|
* the warning by the use of void. In conjunction with the use of -Werror |
* the warning by the use of void. In conjunction with the use of -Werror |
* these warnings prohibit the compilation of the package. This macro |
* these warnings prohibit the compilation of the package. This macro |
* allows us to assign the return value to a variable and then ignore it. |
* allows us to assign the return value to a variable and then ignore it. |
|
* |
|
* __attribute__((unused)) is added for avoiding another warning about set, |
|
* but unused variable. This is produced by unused-but-set-variable switch |
|
* that is enabled by default in gcc 4.6. |
*/ |
*/ |
#if !defined(__GNUC__) || (__GNUC__ < 4) |
#if !defined(__GNUC__) || (__GNUC__ < 4) |
#define IGNORE_RET(x) (void) x |
#define IGNORE_RET(x) (void) x |
#else |
#else |
#define IGNORE_RET(x) \ |
#define IGNORE_RET(x) \ |
do { \ |
do { \ |
int ignore_return; \ | int __attribute__((unused)) ignore_return ;\ |
ignore_return = x; \ | ignore_return = x; \ |
} while (0) |
} while (0) |
#endif |
#endif |
|
|
|
/* This macro is defined to avoid unused-but-set-variable warning |
|
* that is enabled in gcc 4.6 |
|
*/ |
|
|
|
#define IGNORE_UNUSED(x) { x = x; } |
|
|
#endif /* __ISC_DHCP_CDEFS_H__ */ |
#endif /* __ISC_DHCP_CDEFS_H__ */ |