fixed bug which could lead to a seg fault

This commit is contained in:
ulrikey 2007-05-25 16:44:23 +00:00
parent 60f1bb06bd
commit 736292b8ce

View File

@ -313,7 +313,7 @@ hypre_NewCommPkgCreate_core(
upper_bound = response_buf[i*2+1];
count = 0;
/* loop through off_d entries - counting how many are in the range */
while (col_map_off_d[j] <= upper_bound && j < num_cols_off_d)
while (j < num_cols_off_d && col_map_off_d[j] <= upper_bound)
{
j++;
count++;