+/* followup_gnfq: Fix the directory name & modby fields
+ * argv[0] = filsys_id
+ * argv[2] = ascii(quota)
+ */
+
+followup_gnfq(q, sq, v, action, actarg, cl)
+ struct query *q;
+ register struct save_queue *sq;
+ struct validate *v;
+ register int (*action)();
+ register int actarg;
+ client *cl;
+##{
+ register int j;
+ char **argv, *malloc();
+## int id, rowcount;
+## char *name, *label;
+
+ while (sq_get_data(sq, &argv)) {
+ id = atoi(argv[3]);
+ free(argv[3]);
+ argv[3] = malloc(256);
+ name = argv[3];
+ if (id == 0) {
+ label = argv[0];
+## repeat retrieve (name = filesys.#name) where filesys.#label = @label
+ } else {
+## repeat retrieve (name = nfsphys.dir) where nfsphys.nfsphys_id = @id
+ }
+## inquire_equel(rowcount = "rowcount")
+ if (rowcount != 1) {
+ sprintf(argv[3], "#%d", id);
+ }
+
+ id = atoi(argv[6]);
+ free(argv[6]);
+ argv[6] = malloc(256);
+ name = argv[6];
+ if (id > 0)
+## repeat retrieve (name = users.login) where users.users_id = @id
+ else {
+ id = -id;
+## repeat retrieve (name = strings.string) where strings.string_id = @id
+ id = -id;
+ }
+## inquire_equel(rowcount = "rowcount")
+ if (rowcount != 1) {
+ sprintf(argv[6], "#%d", id);
+ }
+ (*action)(q->vcnt, argv, actarg);
+ for (j = 0; j < q->vcnt; j++)
+ free(argv[j]);
+ free(argv);
+ }
+ sq_destroy(sq);
+ return(SMS_SUCCESS);
+##}
+
+