diff options
Diffstat (limited to 'src/Boundary.c')
-rw-r--r-- | src/Boundary.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/src/Boundary.c b/src/Boundary.c index f190d19..c7ae95d 100644 --- a/src/Boundary.c +++ b/src/Boundary.c @@ -362,6 +362,7 @@ CCTK_INT Bdry_Boundary_SelectVarForBCI(CCTK_POINTER GH, retval = 0; current = NULL; previous = NULL; + previous_bcdata = NULL; #ifdef DEBUG printf("Boundary_SelectVarForBCI: called with table_handle=%d, var_index=%d, bc_name=%s\n", table_handle, var_index, bc_name); @@ -581,8 +582,6 @@ CCTK_INT Bdry_Boundary_SelectGroupForBC(CCTK_POINTER GH, { int retval, gi; - retval = 0; - #ifdef DEBUG printf("Boundary_SelectGroupForBC: called for group %s\n", group_name); #endif @@ -644,6 +643,7 @@ CCTK_INT Bdry_Boundary_SelectGroupForBC(CCTK_POINTER GH, @returndesc 0 success -7 invalid group index + -8 group has zero vars or the returncode of @seeroutine Bdry_Boundary_SelectVarForBCI @endreturndesc @@*/ @@ -655,6 +655,8 @@ CCTK_INT Bdry_Boundary_SelectGroupForBCI(CCTK_POINTER GH, { int num_vars, vi, max_vi, retval; + retval = -8; + /* Get var indices from group name */ num_vars = CCTK_NumVarsInGroupI(group_index); if (num_vars<0) @@ -878,6 +880,8 @@ void Boundary_ApplyPhysicalBCs(CCTK_ARGUMENTS) max_num_vars = 0; vars = NULL; /* so that it won't be freed if it was never malloced */ + faces = NULL; /* avoids a compiler warning */ + tables = NULL; /* avoids a compiler warning */ /* Step through each requested physical boundary condition */ for (current_bcdata = bcdata_list; |