ifs_tpfa_assemble(): Coalesce external forces into single branch.

This commit is contained in:
Bård Skaflestad
2012-03-16 14:30:13 +01:00
parent c5c9f58a23
commit b8f3cd90c3

View File

@@ -388,13 +388,15 @@ ifs_tpfa_assemble(struct UnstructuredGrid *G ,
}
is_neumann = 1;
if ((F != NULL) && (F->bc != NULL)) {
is_neumann = assemble_bc_contrib(G, F->bc, trans, h);
}
if (F != NULL) {
if (F->bc != NULL) {
is_neumann = assemble_bc_contrib(G, F->bc, trans, h);
}
if ((F != NULL) && (F->src != NULL)) {
for (c = 0; c < G->number_of_cells; c++) {
h->b[c] += F->src[c];
if (F->src != NULL) {
for (c = 0; c < G->number_of_cells; c++) {
h->b[c] += F->src[c];
}
}
}