1
1

Merge pull request #3310 from marksantcroos/fix/alps_wdir

Bring ALPS ODLS up to par regarding wdir.
Этот коммит содержится в:
Ralph Castain 2017-04-11 17:30:04 -07:00 коммит произвёл GitHub
родитель dadc924cde 27fa8aabd6
Коммит 539f71d0cc
2 изменённых файлов: 28 добавлений и 1 удалений

Просмотреть файл

@ -16,6 +16,8 @@
* Copyright (c) 2011-2014 Los Alamos National Security, LLC. All rights
* reserved.
* Copyright (c) 2013-2017 Intel, Inc. All rights reserved.
* Copyright (c) 2017 Rutgers, The State University of New Jersey.
* All rights reserved.
*
* $COPYRIGHT$
*
@ -423,6 +425,20 @@ static int do_child(orte_odls_spawn_caddy_t *cd, int write_fd)
sigprocmask(0, 0, &sigs);
sigprocmask(SIG_UNBLOCK, &sigs, 0);
/* take us to the correct wdir */
if (NULL != cd->wdir) {
if (0 != chdir(cd->wdir)) {
send_error_show_help(write_fd, 1,
"help-orterun.txt",
"orterun:wdir-not-found",
"orted",
cd->wdir,
orte_process_info.nodename,
cd->child->app_rank);
/* Does not return */
}
}
/* Exec the new executable */
if (10 < opal_output_get_verbosity(orte_odls_base_framework.framework_output)) {

Просмотреть файл

@ -16,6 +16,8 @@
* Copyright (c) 2011-2013 Los Alamos National Security, LLC. All rights
* reserved.
* Copyright (c) 2013-2017 Intel, Inc. All rights reserved.
* Copyright (c) 2017 Rutgers, The State University of New Jersey.
* All rights reserved.
*
* $COPYRIGHT$
*
@ -416,7 +418,16 @@ static int do_child(orte_odls_spawn_caddy_t *cd, int write_fd)
/* take us to the correct wdir */
if (NULL != cd->wdir) {
chdir(cd->wdir);
if (0 != chdir(cd->wdir)) {
send_error_show_help(write_fd, 1,
"help-orterun.txt",
"orterun:wdir-not-found",
"orted",
cd->wdir,
orte_process_info.nodename,
cd->child->app_rank);
/* Does not return */
}
}
/* Exec the new executable */