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

📄 date_proc.c

📁 the source code from the book "UNIX Network Programming" by W. Richard Stevens. i hope it is useful
💻 C
字号:
/* * dateproc.c - remote procedures; called by server stub. */#include	<rpc/rpc.h>	/* standard RPC include file */#include	"date.h"	/* this file is generated by rpcgen *//* * Return the binary date and time. */long *bin_date_1(){	static long	timeval;	/* must be static */	long		time();		/* Unix function */	timeval = time((long *) 0);	return(&timeval);}/* * Convert a binary time and return a human readable string. */char **str_date_1(bintime)long	*bintime;{	static char	*ptr;		/* must be static */	char		*ctime();	/* Unix function */	ptr = ctime(bintime);		/* convert to local time */	return(&ptr);		/* return the address of pointer */}

⌨️ 快捷键说明

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