dect
/
libpcap
Archived
13
0
Fork 0

From Albert Chin: just define __attribute__ as an empty macro if we

don't have __attribute__ support in the compiler.

While we're at it, get rid of the declaration of bpf_error() in
gencode.c, as it's already declared in gencode.h.
This commit is contained in:
guy 2005-04-23 22:27:37 +00:00
parent 6321271094
commit f2c4434b82
2 changed files with 7 additions and 8 deletions

View File

@ -21,7 +21,7 @@
*/
#ifndef lint
static const char rcsid[] _U_ =
"@(#) $Header: /tcpdump/master/libpcap/gencode.c,v 1.221.2.6 2005-04-20 18:23:42 guy Exp $ (LBL)";
"@(#) $Header: /tcpdump/master/libpcap/gencode.c,v 1.221.2.7 2005-04-23 22:27:37 guy Exp $ (LBL)";
#endif
#ifdef HAVE_CONFIG_H
@ -108,8 +108,6 @@ static u_int orig_linktype = -1U, orig_nl = -1U;
static int pcap_fddipad;
#endif
void bpf_error(const char *fmt, ...) __attribute__((noreturn));
/* VARARGS */
void
bpf_error(const char *fmt, ...)

View File

@ -18,7 +18,7 @@
* WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED WARRANTIES OF
* MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
*
* @(#) $Header: /tcpdump/master/libpcap/gencode.h,v 1.60.2.1 2005-04-19 04:26:07 guy Exp $ (LBL)
* @(#) $Header: /tcpdump/master/libpcap/gencode.h,v 1.60.2.2 2005-04-23 22:27:38 guy Exp $ (LBL)
*/
/*
@ -55,6 +55,10 @@
* POSSIBILITY OF SUCH DAMAGE.
*/
#ifndef HAVE___ATTRIBUTE__
#define __attribute__(x)
#endif /* HAVE___ATTRIBUTE__ */
/* Address qualifiers. */
#define Q_HOST 1
@ -290,10 +294,7 @@ struct block *gen_pf_dir(int);
void bpf_optimize(struct block **);
void bpf_error(const char *, ...)
#if HAVE___ATTRIBUTE__
__attribute__((noreturn, format (printf, 1, 2)))
#endif
;
__attribute__((noreturn, format (printf, 1, 2)));
void finish_parse(struct block *);
char *sdup(const char *);