diff --git a/orte/mca/ras/slurm/ras_slurm_module.c b/orte/mca/ras/slurm/ras_slurm_module.c index cce48890ff..8739005ced 100644 --- a/orte/mca/ras/slurm/ras_slurm_module.c +++ b/orte/mca/ras/slurm/ras_slurm_module.c @@ -330,6 +330,7 @@ static int parse_range(char *base, char *range, char ***names) len = strlen(range); base_len = strlen(base); + start = end = 0; /* Look for the beginning of the first number */ diff --git a/orte/mca/sds/slurm/sds_slurm_module.c b/orte/mca/sds/slurm/sds_slurm_module.c index 044bd811ed..d186d67561 100644 --- a/orte/mca/sds/slurm/sds_slurm_module.c +++ b/orte/mca/sds/slurm/sds_slurm_module.c @@ -268,7 +268,8 @@ static int parse_range(char *base, char *range, char ***names) len = strlen(range); base_len = strlen(base); - + start = end = 0; + /* Look for the beginning of the first number */ for (found = false, i = 0; i < len; ++i) {