-/*
- * Copy a string, truncating to the specified length if necessary.
- * Unlike strncpy(), the resulting string is guaranteed to be null-terminated.
- */
- public void
-strtcpy(to, from, len)
- char *to;
- char *from;
- unsigned int len;
-{
- strncpy(to, from, len);
- to[len-1] = '\0';
-}
-