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

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

?? res_comp.c

?? vxworks source code, used for develop vxworks system.
?? C
字號:
/* res_comp.c - expands and compresses domain names in a messge  *//* Copyright 1984-2001 Wind River Systems, Inc. */#include "copyright_wrs.h"/* * Copyright (c) 1985 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 the following conditions * are met: * 1. Redistributions of source code must retain the above copyright *    notice, this list of conditions and the following disclaimer. * 2. Redistributions in binary form must reproduce the above copyright *    notice, this list of conditions and the following disclaimer in the *    documentation and/or other materials provided with the distribution. * 3. All advertising materials mentioning features or use of this software *    must display the following acknowledgement: *	This product includes software developed by the University of *	California, Berkeley and its contributors. * 4. 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 BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE * ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. *//*modification history--------------------01b,17sep01,vvv  fixed compilation warnings01a,13dec96,jag  Cleaned up and rename functions with the resolv prefix.  The                 man pages for these functions appear in resolvLib*/#include <resolvLib.h>#include <stdio.h>static int dn_find();/* * Expand compressed domain name 'comp_dn' to full domain name. * 'msg' is a pointer to the begining of the message, * 'eomorig' points to the first location after the message, * 'exp_dn' is a pointer to a buffer of size 'length' for the result. * Return size of compressed name or -1 if there was an error. */int resolvDNExpand(msg, eomorig, comp_dn, exp_dn, length)	const u_char *msg, *eomorig, *comp_dn;	u_char *exp_dn;	int length;{	register u_char *cp, *dn;	register int n, c;	u_char *eom;	int len = -1, checked = 0;	dn = exp_dn;	cp = (u_char *)comp_dn;	eom = exp_dn + length;	/*	 * fetch next label in domain name	 */	while ((n = *cp++)) {		/*		 * Check for indirection		 */		switch (n & INDIR_MASK) {		case 0:			if (dn != exp_dn) {				if (dn >= eom)					return (-1);				*dn++ = '.';			}			if (dn+n >= eom)				return (-1);			checked += n + 1;			while (--n >= 0) {				if ((c = *cp++) == '.') {					if (dn + n + 2 >= eom)						return (-1);					*dn++ = '\\';				}				*dn++ = c;				if (cp >= eomorig)	/* out of range */					return(-1);			}			break;		case INDIR_MASK:			if (len < 0)				len = cp - comp_dn + 1;			cp = (u_char *)msg + (((n & 0x3f) << 8) | (*cp & 0xff));			if (cp < msg || cp >= eomorig)	/* out of range */				return(-1);			checked += 2;			/*			 * Check for loops in the compressed name;			 * if we've looked at the whole message,			 * there must be a loop.			 */			if (checked >= eomorig - msg)				return (-1);			break;		default:			return (-1);			/* flag error */		}	}	*dn = '\0';	if (len < 0)		len = cp - comp_dn;	return (len);}/* * Compress domain name 'exp_dn' into 'comp_dn'. * Return the size of the compressed name or -1. * 'length' is the size of the array pointed to by 'comp_dn'. * 'dnptrs' is a list of pointers to previous compressed names. dnptrs[0] * is a pointer to the beginning of the message. The list ends with NULL. * 'lastdnptr' is a pointer to the end of the arrary pointed to * by 'dnptrs'. Side effect is to update the list of pointers for * labels inserted into the message as we compress the name. * If 'dnptr' is NULL, we don't try to compress names. If 'lastdnptr' * is NULL, we don't update the list. */int resolvDNComp(exp_dn, comp_dn, length, dnptrs, lastdnptr)	const u_char *exp_dn;	u_char *comp_dn;        int length;        u_char **dnptrs, **lastdnptr;{	register u_char *cp, *dn;	register int c, l;	u_char **cpp = NULL, **lpp = NULL, *sp, *eob;	u_char *msg;	dn = (u_char *)exp_dn;	cp = comp_dn;	eob = cp + length;	if (dnptrs != NULL) {		if ((msg = *dnptrs++) != NULL) {			for (cpp = dnptrs; *cpp != NULL; cpp++)				;			lpp = cpp;	/* end of list to search */		}	} else		msg = NULL;	for (c = *dn++; c != '\0'; ) {		/* look to see if we can use pointers */		if (msg != NULL) {			if ((l = dn_find(dn-1, msg, dnptrs, lpp)) >= 0) {				if (cp+1 >= eob)					return (-1);				*cp++ = (l >> 8) | INDIR_MASK;				*cp++ = l % 256;				return (cp - comp_dn);			}			/* not found, save it */			if (lastdnptr != NULL && cpp < lastdnptr-1) {				*cpp++ = cp;				*cpp = NULL;			}		}		sp = cp++;	/* save ptr to length byte */		do {			if (c == '.') {				c = *dn++;				break;			}			if (c == '\\') {				if ((c = *dn++) == '\0')					break;			}			if (cp >= eob) {				if (msg != NULL)					*lpp = NULL;				return (-1);			}			*cp++ = c;		} while ((c = *dn++) != '\0');		/* catch trailing '.'s but not '..' */		if ((l = cp - sp - 1) == 0 && c == '\0') {			cp--;			break;		}		if (l <= 0 || l > MAXLABEL) {			if (msg != NULL)				*lpp = NULL;			return (-1);		}		*sp = l;	}	if (cp >= eob) {		if (msg != NULL)			*lpp = NULL;		return (-1);	}	*cp++ = '\0';	return (cp - comp_dn);}/* * Skip over a compressed domain name. Return the size or -1. */int __dn_skipname(comp_dn, eom)	const u_char *comp_dn, *eom;{	register u_char *cp;	register int n;	cp = (u_char *)comp_dn;	while (cp < eom && (n = *cp++)) {		/*		 * check for indirection		 */		switch (n & INDIR_MASK) {		case 0:			/* normal case, n == len */			cp += n;			continue;		case INDIR_MASK:	/* indirection */			cp++;			break;		default:		/* illegal type */			return (-1);		}		break;	}	if (cp > eom)		return -1;	return (cp - comp_dn);}/* * Search for expanded name from a list of previously compressed names. * Return the offset from msg if found or -1. * dnptrs is the pointer to the first name on the list, * not the pointer to the start of the message. */static intdn_find(exp_dn, msg, dnptrs, lastdnptr)	u_char *exp_dn, *msg;	u_char **dnptrs, **lastdnptr;{	register u_char *dn, *cp, **cpp;	register int n;	u_char *sp;	for (cpp = dnptrs; cpp < lastdnptr; cpp++) {		dn = exp_dn;		sp = cp = *cpp;		while ((n = *cp++)) {			/*			 * check for indirection			 */			switch (n & INDIR_MASK) {			case 0:		/* normal case, n == len */				while (--n >= 0) {					if (*dn == '.')						goto next;					if (*dn == '\\')						dn++;					if (*dn++ != *cp++)						goto next;				}				if ((n = *dn++) == '\0' && *cp == '\0')					return (sp - msg);				if (n == '.')					continue;				goto next;			default:	/* illegal type */				return (-1);			case INDIR_MASK:	/* indirection */				cp = msg + (((n & 0x3f) << 8) | *cp);			}		}		if (*dn == '\0')			return (sp - msg);	next:	;	}	return (-1);}/* * Routines to insert/extract short/long's. Must account for byte * order and non-alignment problems. This code at least has the * advantage of being portable. * * used by sendmail. */u_short_getshort(msgp)	register u_char *msgp;{	register u_short u;	GETSHORT(u, msgp);	return (u);}uint32_t_getlong(msgp)	u_char *msgp;{	register uint32_t u;	GETLONG(u, msgp);	return (u);}void#ifdef __STDC____putshort(register uint16_t s, register u_char *msgp)#else__putshort(s, msgp)	register uint16_t s;	register u_char *msgp;#endif{	PUTSHORT(s, msgp);}void__putlong(l, msgp)	register uint32_t l;	register u_char *msgp;{	PUTLONG(l, msgp);}

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
一区二区三区国产精华| 精品嫩草影院久久| 亚洲人成电影网站色mp4| av成人动漫在线观看| 最好看的中文字幕久久| av在线一区二区三区| 亚洲蜜桃精久久久久久久| 色欧美片视频在线观看| 亚洲综合一区二区| 精品区一区二区| 国产成人精品亚洲日本在线桃色 | 国产精品成人免费| 色综合久久久网| 丝袜诱惑制服诱惑色一区在线观看| 欧美日韩国产综合视频在线观看| 久久精品999| 欧美激情一区在线| 91久久人澡人人添人人爽欧美| 亚洲成人tv网| 国产午夜精品久久久久久免费视| 成人小视频免费在线观看| 综合久久久久久久| 日韩亚洲电影在线| 成人短视频下载| 天堂va蜜桃一区二区三区| 国产无人区一区二区三区| 91美女福利视频| 久久福利视频一区二区| 国产精品不卡在线| 欧美大片顶级少妇| 一本到高清视频免费精品| 狠狠色丁香婷综合久久| 成人欧美一区二区三区| 91精品国产综合久久香蕉麻豆| 高清国产午夜精品久久久久久| 亚洲激情综合网| 久久久久九九视频| 欧美人牲a欧美精品| 成人午夜电影网站| 免费不卡在线观看| 亚洲午夜久久久久久久久久久| 欧美精品一区二区蜜臀亚洲| 91成人免费电影| 国产精品一区二区91| 亚洲成av人片观看| 国产精品久久久久久亚洲伦| 在线观看91精品国产入口| 国产一区二区在线看| 亚洲国产成人高清精品| 国产精品伦理在线| 26uuu精品一区二区三区四区在线 26uuu精品一区二区在线观看 | 国产精品人人做人人爽人人添| 欧美另类videos死尸| voyeur盗摄精品| 国产真实乱偷精品视频免| 亚洲国产一区在线观看| 亚洲三级在线免费| 国产婷婷精品av在线| 日韩欧美视频一区| 欧美人牲a欧美精品| 91农村精品一区二区在线| 懂色av中文一区二区三区| 久久99精品国产.久久久久久| 亚洲高清视频在线| 亚洲一区在线视频| 亚洲美女一区二区三区| 中文字幕一区在线| 欧美激情一区二区| 精品国产一区二区亚洲人成毛片| 欧美精品xxxxbbbb| 欧美剧在线免费观看网站| 91激情五月电影| 欧美性受极品xxxx喷水| 色欧美片视频在线观看在线视频| thepron国产精品| 成人av网站在线观看免费| 成人久久久精品乱码一区二区三区| 九色综合国产一区二区三区| 99九九99九九九视频精品| 国产成人综合网站| 高清成人免费视频| www.亚洲免费av| 99久久精品99国产精品| 91免费版pro下载短视频| 91啪亚洲精品| 欧美色综合影院| 91精品午夜视频| 日韩欧美一区二区不卡| 久久女同精品一区二区| 国产女人aaa级久久久级| 久久久久久**毛片大全| 国产人久久人人人人爽| 国产精品国产三级国产aⅴ中文| 中文字幕一区二区视频| 26uuu精品一区二区三区四区在线| 国产成人精品午夜视频免费| 在线播放中文一区| 一本色道综合亚洲| 日本精品视频一区二区三区| 欧美三级三级三级爽爽爽| 欧美精品一卡两卡| 精品免费一区二区三区| 国产精品蜜臀在线观看| 亚洲精品第1页| 免费观看在线色综合| 国产成人免费在线视频| 91麻豆精东视频| 91精品在线免费观看| 国产亚洲自拍一区| 一级日本不卡的影视| 美女网站一区二区| 不卡电影免费在线播放一区| 欧美色图激情小说| 久久婷婷久久一区二区三区| 亚洲女人的天堂| 久久精品久久综合| 91香蕉视频在线| 日韩视频一区二区在线观看| 一区二区中文字幕在线| 日韩电影在线观看网站| 成人激情电影免费在线观看| 欧美精品久久99久久在免费线 | 欧美亚洲精品一区| 亚洲国产成人tv| 粉嫩高潮美女一区二区三区| 欧美色综合久久| 欧美激情综合网| 秋霞电影一区二区| 色88888久久久久久影院按摩 | 中文字幕av一区二区三区高| 亚洲一区二区三区四区五区中文 | 国产一区二区三区免费观看| 99re热视频精品| 精品国产青草久久久久福利| 亚洲免费观看视频| 国产一区二区三区蝌蚪| 欧美肥胖老妇做爰| 一区二区三区中文字幕电影 | 国产ts人妖一区二区| 欧美日韩国产不卡| 亚洲人成人一区二区在线观看| 国产在线视频不卡二| 欧美日韩国产免费| 一区二区三区免费观看| 国产精品18久久久久久久网站| 欧美二区三区91| 综合网在线视频| 粉嫩av一区二区三区在线播放| 日韩一区二区高清| 亚洲综合精品久久| 成人开心网精品视频| 久久精品视频一区| 国内精品写真在线观看| 欧美一区二区三区免费在线看| 一区二区三区日本| 色琪琪一区二区三区亚洲区| 国产精品视频你懂的| 国产精品原创巨作av| 精品国产百合女同互慰| 久久国产精品色婷婷| 在线综合视频播放| 视频精品一区二区| 欧美日韩黄色影视| 亚洲成人综合在线| 欧美系列在线观看| 一区二区久久久久| 欧美中文字幕一区二区三区| 自拍偷自拍亚洲精品播放| www.欧美日韩国产在线| 国产精品视频一二三| 成人免费高清在线| 国产精品国产三级国产普通话三级| 国产91丝袜在线观看| 国产人伦精品一区二区| 99久久精品国产观看| 亚洲日本va午夜在线电影| 色综合久久综合中文综合网| 亚洲综合偷拍欧美一区色| 欧美日韩日本视频| 免费成人小视频| 2021国产精品久久精品| 国产福利一区在线| 国产精品美女久久久久av爽李琼| 国产成人精品亚洲午夜麻豆| 最新久久zyz资源站| 一本到三区不卡视频| 亚洲va韩国va欧美va精品| 欧美一区二区女人| 国产老妇另类xxxxx| 亚洲欧美日韩国产另类专区| 一本大道av一区二区在线播放| 亚洲国产wwwccc36天堂| 日韩女优电影在线观看| 国产成人免费高清| 樱花草国产18久久久久| 91精品国产综合久久精品| 国产在线麻豆精品观看| 亚洲欧美一区二区三区国产精品 | 麻豆成人免费电影| 国产午夜精品一区二区三区嫩草|