-
大小: 813KB文件类型: .gz金币: 1下载: 0 次发布日期: 2021-05-29
- 语言: 其他
- 标签: libpcap-1.9. linux
资源简介
linux下libpcap-1.9.0的源码。可以在Linux下编译。参考Readme文件。
代码片段和文件信息
/*
* Copyright (c) 1992 1993 1994 1995 1996
* The Regents of the University of California. All rights reserved.
*
* Redistribution and use in source and binary forms with or without
* modification are permitted provided that: (1) source code distributions
* retain the above copyright notice and this paragraph in its entirety (2)
* distributions including binary code include the above copyright notice and
* this paragraph in its entirety in the documentation or other materials
* provided with the distribution and (3) all advertising materials mentioning
* features or use of this software display the following acknowledgement:
* ‘‘This product includes software developed by the University of California
* Lawrence Berkeley Laboratory and its contributors.‘‘ Neither the name of
* the University nor the names of its contributors may be used to endorse
* or promote products derived from this software without specific prior
* written permission.
* THIS SOFTWARE IS PROVIDED ‘‘AS IS‘‘ AND WITHOUT ANY EXPRESS OR IMPLIED
* WARRANTIES INCLUDING WITHOUT LIMITATION THE IMPLIED WARRANTIES OF
* MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
*/
#ifdef HAVE_CONFIG_H
#include
#endif
#include
#include
#include “optimize.h“
void
bpf_dump(const struct bpf_program *p int option)
{
const struct bpf_insn *insn;
int i;
int n = p->bf_len;
insn = p->bf_insns;
if (option > 2) {
printf(“%d\n“ n);
for (i = 0; i < n; ++insn ++i) {
printf(“%u %u %u %u\n“ insn->code
insn->jt insn->jf insn->k);
}
return ;
}
if (option > 1) {
for (i = 0; i < n; ++insn ++i)
printf(“{ 0x%x %d %d 0x%08x }\n“
insn->code insn->jt insn->jf insn->k);
return;
}
for (i = 0; i < n; ++insn ++i) {
#ifdef BDEBUG
if (i < NBIDS && bids[i] > 0)
printf(“[%02d]“ bids[i] - 1);
else
printf(“ -- “);
#endif
puts(bpf_image(insn i));
}
}
- 上一篇:鸡尾酒会问题测试音频
- 下一篇:发送字符到指定的IP和端口
相关资源
- linux平台 DHT11驱动程序
- ZigBee 协议在Linux上的实现
- 使用Linux的V4L2读取摄像头数据+Opencv图
- 嵌入式Linux系统移植开发-1基于Yocto构
- linux下的QT串口通信
- linux的外文文献
- 老段带你学-鸟哥的Linux私房菜基础+服
- zw_linux0.11带注解源代码.zip
- 基于Linux平台的串口数据接收程序
- ntpdate-4.2.8p12-1.x86_64.rpm
- 东北大学Linux实验报告及代码sk.zip
- understand5.952 for linux破解安装教程
- linux字符设备驱动代码,副实验报告很
- telnet-server-0.17-47.el6.x86_64.rpm和telnet-
- ST7701_854*480显示屏初始化参数
- 最新vivado2019版本,win和linux都有,安
- linux上实现多进程和多线程实现同步互
- linux下使用minicom连接开发板.doc
- ARM linux 和上位机windows10进行TCP/IP网络
- Linux系统下基于Qt的局域网即时通信系
- linux设备驱动详解视频宋宝华百度网盘
- linux 命令解释器
- linux下weblogic安装部署全套
- 全志A13移植Linux所用的配置文件.conf
- unoconv-0.5-1.el6.rf.noarch.rpmunoconv命令插件
- Linuxc 信号的使用
- Linux实验四shell编程
- 基于LinuxTcp聊天室的设计与实现
- qt-opensource-linux-x64-5.7.0.run.txt
- Hadoop安装ubuntu16.04+ hadoop-2.9.1.tar.gz+j
评论
共有 条评论