-/*
- * Rename the given network path to use
- * the kinds of names that we would right here.
- */
-
-char *
-rename(str)
- char str[];
-{
- register char *cp, *cp2;
- char buf[BUFSIZ], path[BUFSIZ];
- register int c, host;
-
- cp = str;
- strcpy(path, "");
- for (;;) {
- if ((c = *cp++) == 0)
- break;
- cp2 = buf;
- while (!any(c, metanet) && c != 0) {
- *cp2++ = c;
- c = *cp++;
- }
- *cp2 = 0;
- if (c == 0) {
- strcat(path, buf);
- break;
- }
- host = netlook(buf, ntype(c));
- strcat(path, netname(host));
- stradd(path, c);
- }
- if (strcmp(str, path) != 0)
- return(savestr(path));
- return(str);
-}
-