Skip to content

Commit

Permalink
Don't define pcap_stream_err() if we're not going to use it.
Browse files Browse the repository at this point in the history
  • Loading branch information
Guy Harris committed Jun 29, 2009
1 parent 8356bb5 commit 6b89856
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions dlpisubs.c
Expand Up @@ -69,7 +69,9 @@ static const char rcsid[] _U_ =
#include "pcap-int.h" #include "pcap-int.h"
#include "dlpisubs.h" #include "dlpisubs.h"


#ifdef HAVE_SYS_BUFMOD_H
static void pcap_stream_err(const char *, int, char *); static void pcap_stream_err(const char *, int, char *);
#endif


/* /*
* Get the packet statistics. * Get the packet statistics.
Expand Down Expand Up @@ -344,6 +346,7 @@ strioctl(int fd, int cmd, int len, char *dp)
return (str.ic_len); return (str.ic_len);
} }


#ifdef HAVE_SYS_BUFMOD_H
/* /*
* Write stream error message to errbuf. * Write stream error message to errbuf.
*/ */
Expand All @@ -352,3 +355,4 @@ pcap_stream_err(const char *func, int err, char *errbuf)
{ {
snprintf(errbuf, PCAP_ERRBUF_SIZE, "%s: %s", func, pcap_strerror(err)); snprintf(errbuf, PCAP_ERRBUF_SIZE, "%s: %s", func, pcap_strerror(err));
} }
#endif

0 comments on commit 6b89856

Please sign in to comment.