⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 basic_defs.h

📁 该软件根据网络数据生成NetFlow记录。NetFlow可用于网络规划、负载均衡、安全监控等
💻 H
字号:
/*  -*- Mode: C;  -*- *//*******************************************************************************                                                                             **   Copyright 2005 University of Cambridge Computer Laboratory.               **                                                                             **   This file is part of Nprobe.                                              **                                                                             **   Nprobe is free software; you can redistribute it and/or modify            **   it under the terms of the GNU General Public License as published by      **   the Free Software Foundation; either version 2 of the License, or         **   (at your option) any later version.                                       **                                                                             **   Nprobe is distributed in the hope that it will be useful,                 **   but WITHOUT ANY WARRANTY; without even the implied warranty of            **   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the             **   GNU General Public License for more details.                              **                                                                             **   You should have received a copy of the GNU General Public License         **   along with Nprobe; if not, write to the Free Software                     **   Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA **                                                                             *******************************************************************************/#ifndef BASIC_DEFS_H#define BASIC_DEFS_H#define DEBUG#include "vers.h"#ifdef __ia64__typedef long ll_t;typedef unsigned long ull_t;#endif#ifdef __i386__typedef long long ll_t;typedef unsigned long long ull_t;#endif#ifndef SWIG_ONLYtypedef ull_t ulonglong;#elsestruct ulonglong {  unsigned int low;  unsigned int high;}; typedef struct ulonglong ulonglong;struct ulong_int{  int half;  int odd;};#endif /* SWIG_ONLY */#ifndef SWIG #ifndef MACRO_BEGIN#define MACRO_BEGIN do {#define MACRO_END } while (0)#endif /* ifndef MACRO_BEGIN */#define NTOHL(x) x = ntohl(x)#endif /* ifndef SWIG *//* * Stuff for maintaining a us clock - driven by incoming packets  * (struct timeval in sk_buff) */#define US_IN_MS 1000#define US_IN_S  1000000#define US_IN_S_LL  1000000LL#ifndef SWIG_ONLYtypedef ll_t us_clock_t;#elsestruct us_clock {  unsigned int us_low;  unsigned int us_high;};typedef struct us_clock us_clock_t;#endif#define TV_TO_US(tv, us)   \MACRO_BEGIN                \  (us) = (tv).tv_sec*US_IN_S_LL + (tv).tv_usec; \MACRO_END/* * Analogue of a struct timeval for python use */#ifdef SWIG_ONLYstruct tval {  int tv_sec;  int tv_usec;};#endif#ifdef __ia64__struct tmval{  int tv_sec;  int tv_usec;};typedef struct tmval tmval;#elsetypedef struct timeval tmval;#endif  #define SERVER 0x1#define CLIENT 0x2#endif /*  BASIC_DEFS_H */

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -