strlcpy(buf, UPREFIX, NL_TEXTMAX);
len = strlcpy(buf, UPREFIX, NL_TEXTMAX);
__strerror(num, buf)	int num;	char *buf;{#define	UPREFIX	"Unknown error: "	register unsigned int errnum;#ifdef NLS	int save_errno;	nl_catd catd;	catd = catopen("libc", 0);#endif	errnum = num;				/* convert to unsigned */	if (errnum < sys_nerr) {#ifdef NLS		strlcpy(buf, catgets(catd, 1, errnum,		    (char *)sys_errlist[errnum]), NL_TEXTMAX);#else		return(sys_errlist[errnum]);#endif	} else {#ifdef NLS		strlcpy(buf, catgets(catd, 1, 0xffff, UPREFIX), NL_TEXTMAX);#else		strlcpy(buf, UPREFIX, NL_TEXTMAX);#endif		strlcat(buf, itoa(errnum), NL_TEXTMAX);		errno = EINVAL;	}#ifdef NLS	save_errno = errno;	catclose(catd);	errno = save_errno;#endif	return buf;}