]> andersk Git - moira.git/blobdiff - gen/hosts.dc
Diane Delgado's changes for a fixed table-locking order
[moira.git] / gen / hosts.dc
index 8119f6e3e99e3e9dae1a511b7bf8019cd0e7d616..46a76745d4bd4c302e23ebe3894574a4660c3f05 100644 (file)
@@ -68,6 +68,11 @@ char **argv;
 
     EXEC SQL WHENEVER SQLERROR GOTO sqlerr;
 
+    /* Acquire the required locks in the appropriate order */
+
+    EXEC SQL SELECT modtime INTO :name FROM machine WHERE mach_id = 0;
+    EXEC SQL SELECT modtime INTO :name FROM hostalias WHERE mach_id = 0;
+
     gettimeofday(&now, NULL);
     
     fprintf(out, "; MIT Network Host Table\n;\n");
This page took 0.036176 seconds and 4 git commands to generate.