diff --git a/src/mca/pcm/base/Makefile.am b/src/mca/pcm/base/Makefile.am index a69dda72d4..8078f0b7c2 100644 --- a/src/mca/pcm/base/Makefile.am +++ b/src/mca/pcm/base/Makefile.am @@ -22,7 +22,6 @@ libmca_pcm_base_la_SOURCES = \ $(headers) \ pcm_base_close.c \ pcm_base_comm.c \ - pcm_base_ioexecvp.c \ pcm_base_job_track.c \ pcm_base_open.c \ pcm_base_select.c \ diff --git a/src/mca/pcm/base/base.h b/src/mca/pcm/base/base.h index fdbe2072bf..fcc1334962 100644 --- a/src/mca/pcm/base/base.h +++ b/src/mca/pcm/base/base.h @@ -48,9 +48,6 @@ extern "C" { */ int mca_pcm_base_build_base_env(char **in_env, int *envc, char ***out_envp); - int mca_pcm_base_ioexecvp(char **cmdv, int showout, char *outbuff, - int outbuffsize, int stderr_is_err); - char* mca_pcm_base_get_username(mca_llm_base_hostfile_node_t *node); /** diff --git a/src/mca/pcm/rsh/Makefile.am b/src/mca/pcm/rsh/Makefile.am index e88686a38d..12dfd5705e 100644 --- a/src/mca/pcm/rsh/Makefile.am +++ b/src/mca/pcm/rsh/Makefile.am @@ -18,6 +18,7 @@ sources = \ pcm_rsh.h \ pcm_rsh_allocate.c \ pcm_rsh_component.c \ + pcm_rsh_ioexecvp.c \ pcm_rsh_kill.c \ pcm_rsh_spawn.c diff --git a/src/mca/pcm/rsh/pcm_rsh.h b/src/mca/pcm/rsh/pcm_rsh.h index 7d4b48e895..d8a230dedc 100644 --- a/src/mca/pcm/rsh/pcm_rsh.h +++ b/src/mca/pcm/rsh/pcm_rsh.h @@ -49,6 +49,9 @@ extern "C" { mca_ns_base_jobid_t jobid, ompi_list_t *nodelist); + int mca_pcm_rsh_ioexecvp(char **cmdv, int showout, char *outbuff, + int outbuffsize, int stderr_is_err); + struct mca_pcm_rsh_module_t { mca_pcm_base_module_t super; diff --git a/src/mca/pcm/base/pcm_base_ioexecvp.c b/src/mca/pcm/rsh/pcm_rsh_ioexecvp.c similarity index 98% rename from src/mca/pcm/base/pcm_base_ioexecvp.c rename to src/mca/pcm/rsh/pcm_rsh_ioexecvp.c index 68e31b7eec..081f112d49 100644 --- a/src/mca/pcm/base/pcm_base_ioexecvp.c +++ b/src/mca/pcm/rsh/pcm_rsh_ioexecvp.c @@ -27,7 +27,7 @@ #include #include "include/constants.h" -#include "mca/pcm/base/base.h" +#include "mca/pcm/rsh/pcm_rsh.h" #include "util/argv.h" /* @@ -43,7 +43,7 @@ * Returns - 0 or OMPI_ERROR */ int -mca_pcm_base_ioexecvp(char **cmdv, int showout, char *outbuff, +mca_pcm_rsh_ioexecvp(char **cmdv, int showout, char *outbuff, int outbuffsize, int stderr_is_err) { int kidstdout[2]; /* child stdout pipe */ diff --git a/src/mca/pcm/rsh/pcm_rsh_spawn.c b/src/mca/pcm/rsh/pcm_rsh_spawn.c index 9c2a00ba90..1415d95d53 100644 --- a/src/mca/pcm/rsh/pcm_rsh_spawn.c +++ b/src/mca/pcm/rsh/pcm_rsh_spawn.c @@ -236,7 +236,7 @@ internal_need_profile(mca_pcm_rsh_module_t *me, cmd0 = strdup(cmdv[0]); shellpath[sizeof(shellpath) - 1] = '\0'; - if (mca_pcm_base_ioexecvp(cmdv, 0, shellpath, + if (mca_pcm_rsh_ioexecvp(cmdv, 0, shellpath, sizeof(shellpath) - 1, stderr_is_error)) { if (errno == EFAULT) {