Patch recommended by Greg Watson for compiling on bproc4 machines.
Needs a review by Tim! This commit was SVN r5233.
Этот коммит содержится в:
родитель
8a7a171a44
Коммит
95d41c650b
@ -34,6 +34,7 @@
|
||||
|
||||
static int orte_ras_bjs_node_state(int node)
|
||||
{
|
||||
#if (BPROC_API_VERSION <= 3)
|
||||
switch(bproc_nodestatus(node)) {
|
||||
case bproc_node_up:
|
||||
return ORTE_NODE_STATE_UP;
|
||||
@ -44,6 +45,18 @@ static int orte_ras_bjs_node_state(int node)
|
||||
default:
|
||||
return ORTE_NODE_STATE_UNKNOWN;
|
||||
}
|
||||
#else
|
||||
char nodestatus[BPROC_STATE_LEN + 1];
|
||||
|
||||
bproc_nodestatus(node, nodestatus, sizeof(nodestatus));
|
||||
if (strcmp(nodestatus, "up") == 0)
|
||||
return ORTE_NODE_STATE_UP;
|
||||
if (strcmp(nodestatus, "down") == 0)
|
||||
return ORTE_NODE_STATE_DOWN;
|
||||
if (strcmp(nodestatus, "boot") == 0)
|
||||
return ORTE_NODE_STATE_REBOOT;
|
||||
return ORTE_NODE_STATE_UNKNOWN;
|
||||
#endif
|
||||
}
|
||||
|
||||
|
||||
|
Загрузка…
x
Ссылка в новой задаче
Block a user