Skip to content

Commit

Permalink
Merge pull request #6568 from hzhou/2306_hydra_exec
Browse files Browse the repository at this point in the history
hydra/mpiexec: detect missing executables

Approved-by: Ken Raffenetti
hzhou authored Jun 23, 2023

Unverified

This user has not yet uploaded their public signing key.
2 parents b578077 + 4131397 commit 51cbd1d
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions src/pm/hydra/mpiexec/mpiexec.c
Original file line number Diff line number Diff line change
@@ -53,6 +53,14 @@ int main(int argc, char **argv)
status = HYD_uii_mpx_get_parameters(argv);
HYDU_ERR_POP(status, "error parsing parameters\n");

/* Check if any exec argument is missing */
for (exec = HYD_uii_mpx_exec_list; exec; exec = exec->next) {
if (exec->exec[0] == NULL) {
HYDU_ERR_SETANDJUMP(status, HYD_INVALID_PARAM,
"Missing executable. Try -h for usages.\n");
}
}

/* The demux engine should be initialized before any sockets are
* created, since it checks for STDIN's validity. If STDIN was
* closed and we opened a socket that got the same fd as STDIN,

0 comments on commit 51cbd1d

Please sign in to comment.