/* tethereal.c
*
- * $Id: tethereal.c,v 1.95 2001/10/26 18:28:16 gram Exp $
+ * $Id: tethereal.c,v 1.97 2001/11/09 07:44:48 guy Exp $
*
* Ethereal - Network traffic analyzer
* By Gerald Combs <gerald@ethereal.com>
#include "print.h"
#include "resolv.h"
#include "util.h"
+#ifdef HAVE_LIBPCAP
+#include "pcap-util.h"
+#endif
#include "conversation.h"
#include "reassemble.h"
#include "plugins.h"
break;
case PREFS_SET_NO_SUCH_PREF:
+ case PREFS_SET_OBSOLETE:
fprintf(stderr, "tethereal: -o flag \"%s\" specifies unknown preference\n",
optarg);
exit(1);
}
}
- ld.linktype = wtap_pcap_encap_to_wtap_encap(pcap_datalink(ld.pch));
+ ld.linktype = wtap_pcap_encap_to_wtap_encap(get_pcap_linktype(ld.pch,
+ cfile.iface));
if (cfile.save_file != NULL) {
/* Set up to write to the capture file. */
if (ld.linktype == WTAP_ENCAP_UNKNOWN) {