-/* $Id $
+/* $Id$
*
* This program dumps the Moira database to a series of output files
* which can be later read back into Moira in the event of a crash.
fprintf(stderr, "Working on %s\n", name);
return f;
}
+
+/*
+ * Trim whitespace off the tail end of a string
+ */
+char *endtrim(char *save)
+{
+ char *t, *s;
+
+ s = save;
+ for (t = s; *t; t++)
+ continue;
+ while (t > s)
+ {
+ --t;
+ if (!isspace(*t))
+ {
+ t++;
+ break;
+ }
+ }
+ if (*t)
+ *t = '\0';
+ return s;
+}