]> andersk Git - moira.git/commitdiff
do "mach_id > 0" not "mach_id != 0" so it doesn't complain about the host
authordanw <danw>
Thu, 28 Jan 1999 17:50:57 +0000 (17:50 +0000)
committerdanw <danw>
Thu, 28 Jan 1999 17:50:57 +0000 (17:50 +0000)
"[ANY]" (mach_id -1)

gen/hosts.pc

index 632e222f07cc1930a05e2a5f2adaed842321ea59..48746700b4f628b4e93d7556e4665a39f469b967 100644 (file)
@@ -119,15 +119,14 @@ int main(int argc, char **argv)
 
   EXEC SQL DECLARE x CURSOR FOR SELECT
     name, mach_id, vendor, model, os, address
-    FROM machine WHERE status = 1 ORDER BY address;
+    FROM machine WHERE status = 1 AND mach_id > 0
+    ORDER BY address;
   EXEC SQL OPEN x;
   while (1)
     {
       EXEC SQL FETCH x INTO :name, :id, :vendor, :model, :os, :addr;
       if (sqlca.sqlcode)
        break;
-      if (id == 0)
-       continue;
       if (!*strtrim(name))
        continue;
       if ((i = strlen(name)) < 9 || !strchr(name, '.') ||
This page took 0.217364 seconds and 5 git commands to generate.