- if (strchr(tapeprefix, ':')) {
- host = tapeprefix;
- tapeprefix = strchr(host, ':');
- *tapeprefix++ = '\0';
+ {
+ int i;
+ char *n;
+
+ if ((n = strchr(tapeprefix, ':'))) {
+ for (i = 0; i < (n - tapeprefix); i++) {
+ if (tapeprefix[i] == '/')
+ break;
+ }
+ if (tapeprefix[i] != '/') {
+ host = tapeprefix;
+ tapeprefix = strchr(host, ':');
+ *tapeprefix++ = '\0';