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

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關(guān)于我們
? 蟲蟲下載站

?? session.c

?? 代理服務(wù)器 squid-2.6.STABLE16
?? C
字號(hào):
/* UNIX RFCNB (RFC1001/RFC1002) NetBIOS implementation *  * Version 1.0 * Session Routines ... *  * Copyright (C) Richard Sharpe 1996 *  *//* * This program 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. *  * This program 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 this program; if not, write to the Free Software * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */#include <string.h>#include <stdlib.h>int RFCNB_errno = 0;int RFCNB_saved_errno = 0;#define RFCNB_ERRNO#include "std-includes.h"#include <netinet/tcp.h>#include "rfcnb-priv.h"#include "rfcnb-util.h"#include "rfcnb-io.h"/* global data structures */char *RFCNB_Error_Strings[] ={    "RFCNBE_OK: Routine completed successfully.",    "RFCNBE_NoSpace: No space available for a malloc call.",    "RFCNBE_BadName: NetBIOS name could not be translated to IP address.",    "RFCNBE_BadRead: Read system call returned an error. Check errno.",    "RFCNBE_BadWrite: Write system call returned an error. Check errno.",    "RFCNBE_ProtErr: A protocol error has occurred.",    "RFCNBE_ConGone: Connection dropped during a read or write system call.",    "RFCNBE_BadHandle: Bad connection handle passed.",    "RFCNBE_BadSocket: Problems creating socket.",    "RFCNBE_ConnectFailed: Connection failed. See errno.",    "RFCNBE_CallRejNLOCN: Call rejected. Not listening on called name.",    "RFCNBE_CallRejNLFCN: Call rejected. Not listening for called name.",    "RFCNBE_CallRejCNNP: Call rejected. Called name not present.",    "RFCNBE_CallRejInfRes: Call rejected. Name present, but insufficient resources.",    "RFCNBE_CallRejUnSpec: Call rejected. Unspecified error.",    "RFCNBE_BadParam: Bad parameters passed to a routine.",    "RFCNBE_Timeout: IO Operation timed out ..."};int RFCNB_Stats[RFCNB_MAX_STATS];void (*Prot_Print_Routine) () = NULL;	/* Pointer to print routine *//* Set up a session with a remote name. We are passed Called_Name as a * string which we convert to a NetBIOS name, ie space terminated, up to * 16 characters only if we need to. If Called_Address is not empty, then * we use it to connect to the remote end, but put in Called_Name ... Called  * Address can be a DNS based name, or a TCP/IP address ... */void *RFCNB_Call(char *Called_Name, char *Calling_Name, char *Called_Address,    int port){    struct RFCNB_Con *con;    struct in_addr Dest_IP;    int Client;    BOOL redirect;    struct redirect_addr *redir_addr;    char *Service_Address;    /* Now, we really should look up the port in /etc/services ... */    if (port == 0)	port = RFCNB_Default_Port;    /* Create a connection structure first */    if ((con = (struct RFCNB_Con *) malloc(sizeof(struct RFCNB_Con))) == NULL) {	/* Error in size */	RFCNB_errno = RFCNBE_NoSpace;	RFCNB_saved_errno = errno;	return (NULL);    }    con->fd = -0;		/* no descriptor yet */    con->rfc_errno = 0;		/* no error yet */    con->timeout = 0;		/* no timeout   */    con->redirects = 0;    con->redirect_list = NULL;	/* Fix bug still in version 0.50 */    /* Resolve that name into an IP address */    Service_Address = Called_Name;    if (strcmp(Called_Address, "") != 0) {	/* If the Called Address = "" */	Service_Address = Called_Address;    }    if ((errno = RFCNB_Name_To_IP(Service_Address, &Dest_IP)) < 0) {	/* Error */	/* No need to modify RFCNB_errno as it was done by RFCNB_Name_To_IP */	return (NULL);    }    /* Now connect to the remote end */    redirect = TRUE;		/* Fudge this one so we go once through */    while (redirect) {		/* Connect and get session info etc */	redirect = FALSE;	/* Assume all OK */	/* Build the redirect info. First one is first addr called */	/* And tack it onto the list of addresses we called        */	if ((redir_addr = (struct redirect_addr *) malloc(sizeof(struct redirect_addr))) == NULL) {	/* Could not get space */	    RFCNB_errno = RFCNBE_NoSpace;	    RFCNB_saved_errno = errno;	    return (NULL);	}	memcpy((char *) &(redir_addr->ip_addr), (char *) &Dest_IP, sizeof(Dest_IP));	redir_addr->port = port;	redir_addr->next = NULL;	if (con->redirect_list == NULL) {	/* Stick on head */	    con->redirect_list = con->last_addr = redir_addr;	} else {	    con->last_addr->next = redir_addr;	    con->last_addr = redir_addr;	}	/* Now, make that connection */	if ((Client = RFCNB_IP_Connect(Dest_IP, port)) < 0) {	/* Error */	    /* No need to modify RFCNB_errno as it was done by RFCNB_IP_Connect */	    return (NULL);	}	con->fd = Client;	/* Now send and handle the RFCNB session request              */	/* If we get a redirect, we will comeback with redirect true 	 * and a new IP address in DEST_IP                            */	if ((errno = RFCNB_Session_Req(con,		    Called_Name,		    Calling_Name,		    &redirect, &Dest_IP, &port)) < 0) {	    /* No need to modify RFCNB_errno as it was done by RFCNB_Session.. */	    return (NULL);	}	if (redirect) {	    /* We have to close the connection, and then try again */	    (con->redirects)++;	    RFCNB_Close(con->fd);	/* Close it */	}    }    return (con);}/* We send a packet to the other end ... for the moment, we treat the  * data as a series of pointers to blocks of data ... we should check the * length ... */intRFCNB_Send(struct RFCNB_Con *Con_Handle, struct RFCNB_Pkt *udata, int Length){    struct RFCNB_Pkt *pkt;    char *hdr;    int len;    /* Plug in the header and send the data */    pkt = RFCNB_Alloc_Pkt(RFCNB_Pkt_Hdr_Len);    if (pkt == NULL) {	RFCNB_errno = RFCNBE_NoSpace;	RFCNB_saved_errno = errno;	return (RFCNBE_Bad);    }    pkt->next = udata;		/* The user data we want to send */    hdr = pkt->data;    /* Following crap is for portability across multiple UNIX machines */    *(hdr + RFCNB_Pkt_Type_Offset) = RFCNB_SESSION_MESSAGE;    RFCNB_Put_Pkt_Len(hdr, Length);#ifdef RFCNB_DEBUG    fprintf(stderr, "Sending packet: ");#endif    if ((len = RFCNB_Put_Pkt(Con_Handle, pkt, Length + RFCNB_Pkt_Hdr_Len)) < 0) {	/* No need to change RFCNB_errno as it was done by put_pkt ...     */	return (RFCNBE_Bad);	/* Should be able to write that lot ... */    }    /* Now we have sent that lot, let's get rid of the RFCNB Header and return */    pkt->next = NULL;    RFCNB_Free_Pkt(pkt);    return (len);}/* We pick up a message from the internet ... We have to worry about  * non-message packets ...                                           */intRFCNB_Recv(void *con_Handle, struct RFCNB_Pkt *Data, int Length){    struct RFCNB_Pkt *pkt;    int ret_len;    if (con_Handle == NULL) {	RFCNB_errno = RFCNBE_BadHandle;	RFCNB_saved_errno = errno;	return (RFCNBE_Bad);    }    /* Now get a packet from below. We allocate a header first */    /* Plug in the header and send the data */    pkt = RFCNB_Alloc_Pkt(RFCNB_Pkt_Hdr_Len);    if (pkt == NULL) {	RFCNB_errno = RFCNBE_NoSpace;	RFCNB_saved_errno = errno;	return (RFCNBE_Bad);    }    pkt->next = Data;		/* Plug in the data portion */    if ((ret_len = RFCNB_Get_Pkt(con_Handle, pkt, Length + RFCNB_Pkt_Hdr_Len)) < 0) {#ifdef RFCNB_DEBUG	fprintf(stderr, "Bad packet return in RFCNB_Recv... \n");#endif	return (RFCNBE_Bad);    }    /* We should check that we go a message and not a keep alive */    pkt->next = NULL;    RFCNB_Free_Pkt(pkt);    return (ret_len);}/* We just disconnect from the other end, as there is nothing in the RFCNB *//* protocol that specifies any exchange as far as I can see                */intRFCNB_Hangup(struct RFCNB_Con *con_Handle){    if (con_Handle != NULL) {	RFCNB_Close(con_Handle->fd);	/* Could this fail? */	free(con_Handle);    }    return 0;}/* Set TCP_NODELAY on the socket                                          */intRFCNB_Set_Sock_NoDelay(struct RFCNB_Con *con_Handle, BOOL yn){    return (setsockopt(con_Handle->fd, IPPROTO_TCP, TCP_NODELAY,	    (char *) &yn, sizeof(yn)));}/* Listen for a connection on a port???, when                             *//* the connection comes in, we return with the connection                 */void *RFCNB_Listen(){    fprintf(stderr, "RFCNB_Listen NOT IMPLEMENTED as yet!\n");    return NULL;}/* Pick up the last error response as a string, hmmm, this routine should *//* have been different ...                                                */voidRFCNB_Get_Error(char *buffer, int buf_len){    if (RFCNB_saved_errno <= 0) {	sprintf(buffer, "%s", RFCNB_Error_Strings[RFCNB_errno]);    } else {	sprintf(buffer, "%s\n\terrno:%s", RFCNB_Error_Strings[RFCNB_errno],	    strerror(RFCNB_saved_errno));    }}/* Pick up the last error response and returns as a code                 */intRFCNB_Get_Last_Error(){    return (RFCNB_errno);}/* Pick up saved errno as well */intRFCNB_Get_Last_Errno(){    return (RFCNB_saved_errno);}/* Pick up the last error response and return in string ...             */voidRFCNB_Get_Error_Msg(int code, char *msg_buf, int len){    strncpy(msg_buf, RFCNB_Error_Strings[abs(code)], len);}/* Register a higher level protocol print routine */voidRFCNB_Register_Print_Routine(void (*fn) ()){    Prot_Print_Routine = fn;}

?? 快捷鍵說明

復(fù)制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號(hào) Ctrl + =
減小字號(hào) Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
美国精品在线观看| 亚洲综合网站在线观看| 国产一区二区精品久久91| 日韩欧美国产小视频| 捆绑变态av一区二区三区| 精品国产免费人成在线观看| 国产又粗又猛又爽又黄91精品| 国产精品视频免费看| 色综合久久88色综合天天免费| 亚洲精选在线视频| 欧美伦理视频网站| 国产精品综合二区| 亚洲人成网站在线| 欧美三级日本三级少妇99| 美女网站在线免费欧美精品| 欧美激情中文字幕| 欧美特级限制片免费在线观看| 亚洲aⅴ怡春院| 精品国产乱码91久久久久久网站| 成人激情小说网站| 亚洲成a人片在线观看中文| 精品乱人伦一区二区三区| 波多野结衣的一区二区三区| 午夜视频一区二区| 国产欧美一区二区精品性色超碰| 在线一区二区观看| 久久国产麻豆精品| 亚洲三级久久久| 337p亚洲精品色噜噜狠狠| 国产精品91xxx| 婷婷久久综合九色国产成人| 久久久蜜臀国产一区二区| 91麻豆福利精品推荐| 精品无人区卡一卡二卡三乱码免费卡| 国产精品私人影院| 日韩欧美三级在线| 色8久久人人97超碰香蕉987| 狠狠色丁香婷综合久久| 亚洲国产欧美在线| 国产调教视频一区| 777精品伊人久久久久大香线蕉| 成人一级片网址| 久久草av在线| 亚洲国产综合在线| 中文字幕中文字幕中文字幕亚洲无线 | 成人午夜短视频| 日本在线观看不卡视频| 亚洲精品网站在线观看| 久久久久97国产精华液好用吗| 欧美日韩免费观看一区二区三区| 成人高清av在线| 国内精品视频一区二区三区八戒| 亚洲一区成人在线| 国产欧美日韩另类视频免费观看| 91精品国产综合久久精品图片 | 久88久久88久久久| 天天操天天色综合| 亚洲午夜国产一区99re久久| 中文字幕一区二区三| 国产三级精品三级在线专区| 欧美变态tickling挠脚心| 538在线一区二区精品国产| 欧美自拍偷拍午夜视频| 日韩欧美另类在线| 欧美日韩大陆在线| 欧美综合天天夜夜久久| av电影在线观看不卡| 成人黄色软件下载| 成人视屏免费看| 丰满亚洲少妇av| 国产99久久久国产精品| 成人免费视频国产在线观看| 国产精品一区专区| 国产麻豆精品theporn| 国产一区三区三区| 国产毛片精品视频| 国产精品18久久久久久vr| 激情成人综合网| 国产综合色在线| 国产精品影视天天线| 成人听书哪个软件好| 不卡av在线网| 99精品欧美一区| 一本到不卡免费一区二区| 色综合久久88色综合天天| 99精品久久免费看蜜臀剧情介绍 | 色综合亚洲欧洲| 欧美在线观看视频在线| 欧美三级中文字幕在线观看| 欧美精品一卡两卡| 欧美xxxxxxxx| 欧美极品少妇xxxxⅹ高跟鞋 | 亚洲婷婷在线视频| 一区二区三区色| 三级在线观看一区二区| 麻豆专区一区二区三区四区五区| 色94色欧美sute亚洲13| 欧美日韩亚洲国产综合| 欧美一区欧美二区| 精品粉嫩超白一线天av| 国产精品日日摸夜夜摸av| 玉米视频成人免费看| 日本网站在线观看一区二区三区| 国产伦精一区二区三区| 99国产精品久久久久| 欧美精品xxxxbbbb| 国产人成一区二区三区影院| 亚洲欧美日韩国产综合在线| 日本视频免费一区| 成人精品视频一区| 欧美日韩色一区| 久久综合九色综合97_久久久| 中文字幕亚洲精品在线观看| 日韩在线一二三区| 丁香另类激情小说| 欧美日韩美少妇| 中文字幕高清不卡| 天堂精品中文字幕在线| 国产经典欧美精品| 欧美电影在线免费观看| 国产色91在线| 青草av.久久免费一区| 不卡视频一二三| 日韩一区二区免费视频| 亚洲女厕所小便bbb| 久久精品国产精品亚洲精品| 91片黄在线观看| 久久网站热最新地址| 一区二区三区成人在线视频| 国产jizzjizz一区二区| 欧美日本韩国一区| 亚洲人成影院在线观看| 国产伦精一区二区三区| 欧美巨大另类极品videosbest| 久久免费电影网| 日日嗨av一区二区三区四区| 色伊人久久综合中文字幕| 国产调教视频一区| 久久精品国产999大香线蕉| 欧美怡红院视频| 亚洲欧美一区二区在线观看| 国产真实精品久久二三区| 91精品久久久久久蜜臀| 亚洲柠檬福利资源导航| 白白色 亚洲乱淫| 久久久精品国产免费观看同学| 人禽交欧美网站| 欧美色精品在线视频| 一区二区在线观看视频在线观看| 国产高清一区日本| 久久夜色精品国产噜噜av| 蜜臀av在线播放一区二区三区| 欧美在线免费播放| 亚洲精品视频在线观看免费| www..com久久爱| 久久久精品免费观看| 国产福利精品一区二区| 久久久久久久久97黄色工厂| 精品中文字幕一区二区小辣椒| 日韩三级视频在线看| 三级一区在线视频先锋| 91精品国产91久久综合桃花| 亚洲成人动漫在线观看| 欧美日韩国产综合一区二区 | 精品一区二区影视| 欧美一区二区三区不卡| 麻豆精品在线视频| 欧美一区二区三区在线| 免费的国产精品| 日韩欧美国产综合| 久久精品国产**网站演员| 欧美成人福利视频| 精品一区二区精品| 国产日韩精品一区二区三区| 成人性生交大片免费看中文网站| 国产精品国产三级国产普通话三级| 99久久夜色精品国产网站| 一区二区三区视频在线看| 欧美日韩亚洲综合| 麻豆精品视频在线观看视频| 欧美成人官网二区| 国产成人综合亚洲91猫咪| 日韩一区日韩二区| 91官网在线免费观看| 人人超碰91尤物精品国产| 久久久久成人黄色影片| www.日韩大片| 亚洲国产视频一区| 日韩欧美一二三四区| 丁香婷婷综合激情五月色| 亚洲免费在线视频一区 二区| 在线观看成人小视频| 蜜臂av日日欢夜夜爽一区| 国产亚洲一区二区在线观看| 99re亚洲国产精品| 日本女人一区二区三区| 中文欧美字幕免费| 欧美亚洲图片小说| 国产最新精品免费| 一级精品视频在线观看宜春院 |