亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? m2tcplib.c

?? vxwork源代碼
?? C
?? 第 1 頁 / 共 2 頁
字號:
/* m2TcpLib.c - MIB-II TCP-group API for SNMP agents *//* Copyright 1984 - 2001 Wind River Systems, Inc. */#include "copyright_wrs.h"/*modification history--------------------01f,15oct01,rae  merge from truestack ver 01j, base 01e (VIRTUAL_STACK)01e,08mar97,vin  added changes to accomodate changes in pcb structure.01d,25jan95,jdi  doc cleanup.01c,11nov94,rhp  edit man pages01b,10nov94,rhp  fixed typo in m2TcpInit man page01a,08dec93,jag  written*//*DESCRIPTIONThis library provides MIB-II services for the TCP group.  It provides routinesto initialize the group, access the group global variables, read the tableof TCP connections, and change the state of a TCP connection.  For a broaderdescription of MIB-II services, see the manual entry for m2Lib.To use this feature, include the following component:INCLUDE_MIB2_TCPUSING THIS LIBRARYThis library can be initialized and deleted by calling m2TcpInit() andm2TcpDelete() respectively, if only the TCP group's services are needed.If full MIB-II support is used, this group and all other groups can beinitialized and deleted by calling m2Init() and m2Delete().The group global variables are accessed by callingm2TcpGroupInfoGet() as follows:.CS    M2_TCP   tcpVars;    if (m2TcpGroupInfoGet (&tcpVars) == OK)	/@ values in tcpVars are valid @/.CEThe TCP table of connections can be accessed in lexicographical order.  Thefirst entry in the table can be accessed by setting the table index tozero.  Every other entry thereafter can be accessed by passing tom2TcpConnTblEntryGet() the index retrieved in the previous invocationincremented to the next lexicographical value by givingM2_NEXT_VALUE as the search parameter.  For example:.CSM2_TCPCONNTBL  tcpEntry;    /@ Specify a zero index to get the first entry in the table @/    tcpEntry.tcpConnLocalAddress = 0; /@ Local IP address in host byte order @/    tcpEntry.tcpConnLocalPort    = 0; /@ Local TCP port                    @/    tcpEntry.tcpConnRemAddress   = 0; /@ remote IP address                 @/    tcpEntry.tcpConnRemPort      = 0; /@ remote TCP port in host byte order  @/    /@ get the first entry in the table @/    if ((m2TcpConnTblEntryGet (M2_NEXT_VALUE, &tcpEntry) == OK)	/@ values in tcpEntry in the first entry are valid  @/    /@ process first entry in the table @/    /@      * For the next call, increment the index returned in the previous call.     * The increment is to the next possible lexicographic entry; for     * example, if the returned index was 147.11.46.8.2000.147.11.46.158.1000     * the index passed in the next invocation should be      * 147.11.46.8.2000.147.11.46.158.1001.  If an entry in the table     * matches the specified index, then that entry is returned.       * Otherwise the closest entry following it, in lexicographic order,     * is returned.     @/    /@ get the second entry in the table @/    if ((m2TcpConnTblEntryGet (M2_NEXT_VALUE, &tcpEntry) == OK)	/@ values in tcpEntry in the second entry are valid  @/.CEThe TCP table of connections allows only for a connection to be deleted asspecified in the MIB-II.  For example: .CS    M2_TCPCONNTBL  tcpEntry;    /@ Fill in the index for the connection to be deleted in the table @/    /@ Local IP address in host byte order, and local port number @/    tcpEntry.tcpConnLocalAddress = 0x930b2e08;    tcpEntry.tcpConnLocalPort    = 3000;    /@ Remote IP address in host byte order, and remote port number @/    tcpEntry.tcpConnRemAddress   = 0x930b2e9e;    tcpEntry.tcpConnRemPort      = 3000;    tcpEntry.tcpConnState        = 12;	/@ MIB-II state value for delete @/    /@ set the entry in the table @/    if ((m2TcpConnTblEntrySet (&tcpEntry) == OK)	/@ tcpEntry deleted successfuly @/.CEINCLUDE FILES: m2Lib.h SEE ALSO:m2Lib, m2IfLib, m2IpLib, m2IcmpLib, m2UdpLib, m2SysLib*//* includes */#include "vxWorks.h"#include "m2Lib.h"#include <socket.h>#include <net/route.h>#include <netinet/in.h>#include <netinet/tcp.h>#include <netinet/tcp_timer.h>#include <netinet/tcp_fsm.h>#include <netinet/tcp_var.h>#include <netinet/tcp_timer.h>#include <netinet/in_pcb.h>#include <net/protosw.h>#include <private/iosLibP.h>#ifdef VIRTUAL_STACK#include "netinet/vsLib.h"#endif/* defines *//* MIB-II TCP state definitions */#define M2TCP_CLOSED        1#define M2TCP_LISTEN        2#define M2TCP_SYNSENT       3#define M2TCP_SYNRECEIVED   4#define M2TCP_ESTABLISHED   5#define M2TCP_FINWAIT1      6#define M2TCP_FINWAIT2      7#define M2TCP_CLOSEWAIT     8#define M2TCP_LASTACK       9#define M2TCP_CLOSING       10#define M2TCP_TIMEWAIT      11#define M2TCP_DELETETCB     12/* globals *//*  * This table maps the BSD TCP states to the MIB-II TCP specified states. The * table is indexed using the BSD TCP states. */LOCAL long m2TcpStates [TCP_NSTATES] =	{	M2TCP_CLOSED,            /* TCPS_CLOSED       -> M2TCP_CLOSED */	M2TCP_LISTEN,            /* TCPS_LISTEN       -> M2TCP_LISTEN */	M2TCP_SYNSENT,           /* TCPS_SYN_SENT     -> M2TCP_SYNSENT */	M2TCP_SYNRECEIVED,       /* TCPS_SYN_RECEIVED -> M2TCP_SYNRECEIVED */	M2TCP_ESTABLISHED,       /* TCPS_ESTABLISHED  -> M2TCP_ESTABLISHED */	M2TCP_CLOSEWAIT,         /* TCPS_CLOSE_WAIT   -> M2TCP_CLOSEWAIT */	M2TCP_FINWAIT1,          /* TCPS_FIN_WAIT_1   -> M2TCP_FINWAIT1  */	M2TCP_CLOSING,           /* TCPS_CLOSING      -> M2TCP_CLOSING */	M2TCP_LASTACK,           /* TCPS_LAST_ACK     -> M2TCP_LASTACK */	M2TCP_FINWAIT2,          /* TCPS_FIN_WAIT_2   -> M2TCP_FINWAIT2 */        M2TCP_TIMEWAIT,          /* TCPS_TIME_WAIT    -> M2TCP_TIMEWAIT */	};/********************************************************************************* m2TcpInit - initialize MIB-II TCP-group access** This routine allocates the resources needed to allow access to the TCP * MIB-II variables.  This routine must be called before any TCP variables* can be accessed.** RETURNS: OK, always.** SEE ALSO: * m2TcpGroupInfoGet(), m2TcpConnEntryGet(), m2TcpConnEntrySet(), m2TcpDelete()*/STATUS m2TcpInit (void)    {    return (OK);    }/******************************************************************************** m2TcpGroupInfoGet - get MIB-II TCP-group scalar variables** This routine fills in the TCP structure pointed to by <pTcpInfo> with the* values of MIB-II TCP-group scalar variables.** RETURNS: OK, or ERROR if <pTcpInfo> is not a valid pointer.** ERRNO:* S_m2Lib_INVALID_PARAMETER** SEE ALSO: * m2TcpInit(), m2TcpConnEntryGet(), m2TcpConnEntrySet(), m2TcpDelete()*/STATUS m2TcpGroupInfoGet    (    M2_TCPINFO * pTcpInfo 	/* pointer to the TCP group structure */    )    {    int            netLock;     /* Use to secure the Network Code Access */    struct inpcb * pInpCb;	/* Ptr to an internet control block */    struct tcpcb * pTcpCb;	/* Ptr to a TCP connection control block */     /* Validate Pointer to TCP structure */     if (pTcpInfo == NULL)	{	errnoSet (S_m2Lib_INVALID_PARAMETER);        return (ERROR);	}     netLock = splnet ();        /* Get exclusive access to Network Code */    /* Traverse the list of TCP control block and count the # of connections */#ifdef VIRTUAL_STACK    /*     * To avoid introducing a conflict with the "tcpcb" structure tag,     * virtual stacks do not alias the head of the pcb list.     */    for (pInpCb = tcb.lh_first, pTcpInfo->tcpCurrEstab = 0;#else    for (pInpCb = tcpcb.lh_first, pTcpInfo->tcpCurrEstab = 0;#endif /* VIRTUAL_STACK */         pInpCb != NULL; pInpCb = pInpCb->inp_list.le_next)        {        /* Get TCP Connection control structure */         pTcpCb = (struct tcpcb *) pInpCb->inp_ppcb;         if ((pTcpCb->t_state == TCPS_ESTABLISHED) ||            (pTcpCb->t_state == TCPS_CLOSE_WAIT))            pTcpInfo->tcpCurrEstab++;        }     splx (netLock);             /* Give up exclusive access to Network Code */     pTcpInfo->tcpRtoAlgorithm           = M2_tcpRtoAlgorithm_vanj;    pTcpInfo->tcpRtoMin                 = (TCPTV_MIN * 1000) / PR_SLOWHZ;    pTcpInfo->tcpRtoMax                 = (TCPTV_REXMTMAX * 1000) / PR_SLOWHZ;     /* The Maximum number of TCP connections is determined Dynamically == -1 */     pTcpInfo->tcpMaxConn                = -1;     pTcpInfo->tcpActiveOpens            = tcpstat.tcps_connattempt;    pTcpInfo->tcpPassiveOpens           = tcpstat.tcps_accepts;    pTcpInfo->tcpAttemptFails           = tcpstat.tcps_conndrops;    pTcpInfo->tcpEstabResets            = tcpstat.tcps_drops;    pTcpInfo->tcpInSegs                 = tcpstat.tcps_rcvtotal;     pTcpInfo->tcpOutSegs                = tcpstat.tcps_sndtotal -                                          tcpstat.tcps_sndrexmitpack -                                          tcpstat.tcps_persisttimeo;     pTcpInfo->tcpRetransSegs            = tcpstat.tcps_sndrexmitpack;     pTcpInfo->tcpInErrs                 = tcpstat.tcps_rcvbadsum +                                          tcpstat.tcps_rcvbadoff +                                          tcpstat.tcps_rcvshort;#ifdef VIRTUAL_STACK    /*     * (Former) tcpOutRsts global renamed for virtual stacks to prevent     * name conflict with existing structure element.     */    pTcpInfo->tcpOutRsts                = tcpOutResets;#else    pTcpInfo->tcpOutRsts                = tcpOutRsts;#endif    return (OK);    }/******************************************************************************** tcpConnCmp -  compare two TCP connections in lexicographical order** This routine compares two TCP connection control blocks.  It compares the* value 1 with value 2.  It returns equal, value 1 greater than * value 2, or value 1 less than value 2.  The comparison is done based on the* lexicographical order specified by MIB-II.

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
一区二区三区日韩在线观看| 欧美精品三级在线观看| 91看片淫黄大片一级在线观看| 国产精品午夜电影| 99精品热视频| 亚洲图片欧美视频| 精品国产精品网麻豆系列| 不卡视频一二三四| 免费看精品久久片| 国产欧美日韩在线| 91精品国产欧美一区二区18| 成人一区二区三区视频| 亚洲欧美日韩综合aⅴ视频| 欧美一区永久视频免费观看| 五月婷婷另类国产| 成人免费在线播放视频| 在线亚洲免费视频| 欧美人动与zoxxxx乱| 高清在线观看日韩| 亚洲午夜久久久久久久久久久| 精品欧美一区二区三区精品久久 | 久久久不卡网国产精品一区| 成人性生交大片免费看视频在线 | 中文字幕成人网| 69久久夜色精品国产69蝌蚪网| 国产.精品.日韩.另类.中文.在线.播放 | 国产99精品在线观看| 精品一区二区三区免费| 一区二区三区国产| 亚洲欧美日韩中文播放 | 日韩电影在线观看电影| 国产精品美女久久久久aⅴ| 欧美变态tickle挠乳网站| 欧美日韩三级一区| 欧美日韩在线播放一区| 欧美日韩精品一区二区三区四区| 欧美日韩国产综合视频在线观看| 一本大道综合伊人精品热热 | 国产精品天天摸av网| 最新国产精品久久精品| 一区av在线播放| 久久99国内精品| 91美女视频网站| 欧美丝袜自拍制服另类| 欧美日韩成人综合在线一区二区| 26uuu亚洲综合色| 麻豆久久久久久久| 日本韩国视频一区二区| 91电影在线观看| 日韩欧美国产一区在线观看| 国产午夜精品久久久久久久| 亚洲女同女同女同女同女同69| 亚洲第一二三四区| proumb性欧美在线观看| 久久视频一区二区| 1区2区3区欧美| 久草精品在线观看| 欧美日韩日日摸| 亚洲欧美另类图片小说| 国产在线精品一区二区| 欧美人成免费网站| 亚洲色图欧美激情| 国产精品一区二区黑丝| 久久综合久久99| 日韩高清不卡一区二区三区| 9色porny自拍视频一区二区| 久久蜜桃一区二区| 视频一区中文字幕国产| 国产精品理论片在线观看| 激情综合色播五月| 91精品免费观看| 午夜欧美在线一二页| 欧美无乱码久久久免费午夜一区| 欧美国产日韩在线观看| 五月婷婷综合网| 欧美精品日日鲁夜夜添| 天堂在线亚洲视频| 欧美一区二区精品| 成人午夜视频在线观看| 国产精品久久久久久妇女6080 | 日韩欧美视频在线| 国产乱色国产精品免费视频| 国产亚洲午夜高清国产拍精品| 精品一区二区三区久久久| 久久久久久久久久久久电影| 色偷偷成人一区二区三区91| 一区二区三区自拍| 久久女同精品一区二区| 91色九色蝌蚪| 久久亚洲欧美国产精品乐播| 国产成人精品免费一区二区| 亚洲已满18点击进入久久| 精品久久国产字幕高潮| 91免费视频网址| 青青草国产精品97视觉盛宴 | 色婷婷综合久久久中文一区二区| 午夜久久久久久电影| 久久久久久久综合日本| 欧美日韩午夜精品| 国产精品456露脸| 久久精品国产色蜜蜜麻豆| 一区二区三区四区不卡视频| 久久久久国产精品麻豆| 日韩一区和二区| 欧美人妇做爰xxxⅹ性高电影| 国产不卡在线播放| 亚洲成av人**亚洲成av**| 国产精品国产自产拍在线| 欧美一级专区免费大片| 久久亚洲一区二区三区明星换脸 | 欧美丝袜丝交足nylons| 不卡一二三区首页| 丁香激情综合国产| 国产精品亚洲人在线观看| 国产乱码精品一区二区三区av | 中文字幕免费观看一区| 国产精品色呦呦| 亚洲色图欧美偷拍| 亚洲青青青在线视频| 中文字幕一区免费在线观看| 欧美激情一区二区三区蜜桃视频| 久久久久久久久岛国免费| 国产人成一区二区三区影院| 久久九九99视频| 亚洲精品乱码久久久久久日本蜜臀| 国产精品久久久久久户外露出 | ●精品国产综合乱码久久久久 | 在线不卡中文字幕播放| 欧美一区日韩一区| 中文无字幕一区二区三区| 中文字幕在线不卡一区二区三区| 1区2区3区国产精品| 麻豆91精品91久久久的内涵| 暴力调教一区二区三区| 欧美日韩一区二区在线观看| 国产天堂亚洲国产碰碰| 一区二区三区视频在线看| 激情图区综合网| 欧美高清视频不卡网| 亚洲人成网站在线| 精品在线观看视频| 欧美巨大另类极品videosbest | 国产美女精品在线| 日韩精品综合一本久道在线视频| 色偷偷成人一区二区三区91| 日本一区二区三区国色天香 | 激情综合五月婷婷| 欧美日韩一区二区电影| 亚洲欧美在线视频| 国产成a人亚洲| 欧美精品一区二区三区高清aⅴ| 天天色 色综合| 欧美性xxxxx极品少妇| 综合精品久久久| 91色在线porny| 亚洲福利视频一区| 在线电影国产精品| 日韩精品欧美成人高清一区二区| 欧美三区免费完整视频在线观看| 国产精品欧美精品| 成人综合婷婷国产精品久久免费| 日韩无一区二区| 风流少妇一区二区| 亚洲男人天堂av| 91精品国产高清一区二区三区| 亚洲成在人线在线播放| 精品视频一区二区不卡| 欧美成人一区二区三区| 经典三级一区二区| 中文字幕精品一区二区三区精品| 成人一区二区三区视频| 亚洲一区二区在线播放相泽| 5566中文字幕一区二区电影| 九色综合国产一区二区三区| 国产调教视频一区| 在线影院国内精品| 精品一区二区三区在线观看国产| 亚洲免费观看高清完整版在线观看| 欧美二区在线观看| 成人精品视频一区二区三区尤物| 亚洲成人午夜影院| 亚洲三级电影全部在线观看高清| 日韩精品一区二区三区蜜臀| 91国偷自产一区二区三区观看| 国产一区 二区 三区一级| 日韩中文字幕不卡| 亚洲综合一区在线| 亚洲视频一区二区在线观看| 69av一区二区三区| 7777女厕盗摄久久久| jizzjizzjizz欧美| 成人综合日日夜夜| 国内精品视频一区二区三区八戒| 亚洲精品免费在线播放| 欧美激情一区二区在线| 久久精品这里都是精品| 欧日韩精品视频| 国产91精品欧美| 99精品视频在线播放观看| 91在线免费看|