资源简介
tcl8.6.8-src.tar.gz 最新版本 linux管理工具 欢迎下载
代码片段和文件信息
/*
* Copyright (C) 2000-2003 Damien Miller. All rights reserved.
* Copyright (C) 1999 WIDE Project. 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. Neither the name of the project 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 PROJECT 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 PROJECT 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.
*/
/*
* Pseudo-implementation of RFC2553 name / address resolution functions
*
* But these functions are not implemented correctly. The minimum subset
* is implemented for ssh use only. For example this routine assumes
* that ai_family is AF_INET. Don‘t use it for another purpose.
*/
#include “tclInt.h“
TCL_DECLARE_MUTEX(netdbMutex)
#ifndef HAVE_GETNAMEINFO
#ifndef HAVE_STRLCPY
static size_t
strlcpy(char *dst const char *src size_t siz)
{
char *d = dst;
const char *s = src;
size_t n = siz;
/* Copy as many bytes as will fit */
if (n != 0 && --n != 0) {
do {
if ((*d++ = *s++) == 0)
break;
} while (--n != 0);
}
/* Not enough room in dst add NUL and traverse rest of src */
if (n == 0) {
if (siz != 0)
*d = ‘\0‘; /* NUL-terminate dst */
while (*s++)
;
}
return(s - src - 1); /* count does not include NUL */
}
#endif
int fake_getnameinfo(const struct sockaddr *sa size_t salen char *host
size_t hostlen char *serv size_t servlen int flags)
{
struct sockaddr_in *sin = (struct sockaddr_in *)sa;
struct hostent *hp;
char tmpserv[16];
if (sa->sa_family != AF_UNSPEC && sa->sa_fam
- 上一篇:JMonkeyEngine 中文教程
- 下一篇:音频频谱柱状显示电路设计讲解
相关资源
- TCL-S1916 ,1924交换机管理程序
- 易语言GDI三角板源码
- instantclient_12_2.zip
- IPOP华为网络自动化测试神器
- TCL开启ADB工具
- 地形点云.pcd
- tcl8.4.16安装包
- Twemproxy需要的依赖,加Redis安装包,
- 建筑物的地面扫描点云数据
- Tcl/tk软件包
- 中科院汉语词法分析系统ICTCLAS安装包
- ICTCLAS2009版中文分词系统
- freeICTCLAS中科院中文分词(拼音中文输
- NS2 TCL脚本
- linux expect安装及expect,tcl安装包
- instantclient-jdbc-windows.x64-18.3.0.0.0dbru.
- restclient 火狐插件
- NS与网络模拟
- TCL相关资料
- Packtpub.Tcl.8.5.Network.Programming.Jul.2010.
- windows下基于QT5.7的mqttClient测试上位机
- ModelSim_command reference manual 10.5c.pdf
- NextCloud客户端For 安卓V3.5.0
- tcl8.5.12-src.tar.gz
- tcl8.4.11 和 expect 5.45.5
- instantclient-odbc-windows.x64-11.2.0.3.0.zip
- tcl/tk 8.4 for windows
- CloudCompare源码
- instantclient-basic-nt-11.2.0.3.0
- TCL 王牌数字芯12进48出电话交换机软件
评论
共有 条评论