- various bug fixes and improvements

- modified automatic instrument detection on six and tecs client
This commit is contained in:
zolliker
2005-11-17 07:58:07 +00:00
parent 01fce80d95
commit 4c7f439377
5 changed files with 31 additions and 8 deletions

View File

@@ -674,9 +674,20 @@ int main (int argc, char *argv[]) {
, host, sizeof host, &port);
ent = gethostbyname(host);
if (!ent) {
PutC("unknown host: ");
PutC(host);
PutC("\n");
if (hostArg == NULL || hostArg[0] <= ' ') {
snprintf(host, sizeof host, "%s", getenv("HOST"));
hostArg = host;
}
PutC(service);
PutC(" on ");
PutC(hostArg);
PutC(" not found in InstrumentHostList\n");
p=getenv("InstrumentHostList");
if (p) {
PutC("(");
PutC(p);
PutC(")\n");
}
return 0;
}
snprintf(host, sizeof host, "%s", ent->h_name);