114 |
|
id = octname!=NULL ? octname : progname; |
115 |
|
/* check device table */ |
116 |
|
for (i = 0; devtable[i].name; i++) |
117 |
< |
if (!strcmp(dname, devtable[i].name)) |
117 |
> |
if (!strcmp(dname, devtable[i].name)) { |
118 |
|
if ((dev = (*devtable[i].init)(dname, id)) == NULL) { |
119 |
|
sprintf(errmsg, "cannot initialize %s", dname); |
120 |
|
error(USER, errmsg); |
121 |
|
} else |
122 |
|
return; |
123 |
+ |
} |
124 |
|
/* not there, try exec */ |
125 |
|
if ((dev = comm_init(dname, id)) == NULL) { |
126 |
|
sprintf(errmsg, "cannot start device \"%s\"", dname); |