*/
#include <h/mh.h>
+#include <h/utils.h>
/*
* 1) If we are using an external rmmproc, then exec it.
/* Mark that the sequence information has changed */
mp->msgflags |= SEQMOD;
+ /*
+ * Write out the sequence and context files; this will release
+ * any locks before the rmmproc is called.
+ */
+
+ seq_save (mp);
+ context_save ();
+
vec = argsplit(rmmproc, &prog, &vecp);
/*
*/
if (mp->numsel + vecp + 1 > MAXARGS)
- vec = (char **) realloc (vec, (size_t) ((mp->numsel + vecp + 1) *
+ vec = (char **) mh_xrealloc (vec,
+ (size_t) ((mp->numsel + vecp + 1) *
sizeof(*vec)));
if (vec == NULL)
adios (NULL, "unable to allocate exec vector");
if (unlink_msgs) {
/* just unlink the messages */
- if (unlink (dp) == -1) {
+ if (m_unlink (dp) == -1) {
admonish (dp, "unable to unlink");
retval = -1;
continue;
/* Mark that the sequence information has changed */
mp->msgflags |= SEQMOD;
+ /*
+ * Write out sequence and context files
+ */
+
+ seq_save (mp);
+ context_save ();
+
return retval;
}