spandsp
0.0.6
|
00001 /* 00002 * SpanDSP - a series of DSP components for telephony 00003 * 00004 * pcap_parse.h 00005 * 00006 * Written by Steve Underwood <steveu@coppice.org> 00007 * 00008 * Copyright (C) 2009 Steve Underwood 00009 * 00010 * All rights reserved. 00011 * 00012 * This program is free software; you can redistribute it and/or modify 00013 * it under the terms of the GNU General Public License version 2, as 00014 * published by the Free Software Foundation. 00015 * 00016 * This program is distributed in the hope that it will be useful, 00017 * but WITHOUT ANY WARRANTY; without even the implied warranty of 00018 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 00019 * GNU General Public License for more details. 00020 * 00021 * You should have received a copy of the GNU General Public License 00022 * along with this program; if not, write to the Free Software 00023 * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. 00024 */ 00025 00026 /*! \file */ 00027 00028 #if !defined(_SPANDSP_PCAP_PARSE_H_) 00029 #define _SPANDSP_PCAP_PARSE_H_ 00030 00031 #if defined(__cplusplus) 00032 extern "C" 00033 { 00034 #endif 00035 00036 typedef int (pcap_timing_update_handler_t)(void *user_data, struct timeval *ts); 00037 typedef int (pcap_packet_handler_t)(void *user_data, const uint8_t *pkt, int len); 00038 00039 00040 int pcap_scan_pkts(const char *file, 00041 uint32_t src_addr, 00042 uint16_t src_port, 00043 uint32_t dest_addr, 00044 uint16_t dest_port, 00045 pcap_timing_update_handler_t *timing_update_handler, 00046 pcap_packet_handler_t *packet_handler, 00047 void *user_data); 00048 00049 #if defined(__cplusplus) 00050 } 00051 #endif 00052 00053 #endif 00054 /*- End of file ------------------------------------------------------------*/