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

📄 hstrerror.c

📁 unix网络编程卷1:套接口API的全书源码
💻 C
字号:
/* * Return a string containing some additional information after a * host name or address lookup error - gethostbyname() or gethostbyaddr(). * * This is only compiled if the local host does not provide it--recent * versions of BIND supply this function. */#include	"unp.h"const char *hstrerror(int err){	if (err == 0)		return("no error");	if (err == HOST_NOT_FOUND)		return("Unknown host");	if (err == TRY_AGAIN)		return("Hostname lookup failure");	if (err == NO_RECOVERY)		return("Unknown server error");	if (err == NO_DATA)        return("No address associated with name");	return("unknown error");}

⌨️ 快捷键说明

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