Don't attempt to allocate_geometry() if we fail to construct cell topology.

This commit is contained in:
Bård Skaflestad 2012-03-02 17:43:48 +01:00
parent da19df122f
commit fb7ca8a91d

View File

@ -217,9 +217,9 @@ preprocess (const struct grdecl *in, double tol)
/* allocate and fill g->cell_faces/g->cell_facepos and
* g->cell_facetag */
fill_cell_topology(&pg, g);
ok = fill_cell_topology(&pg, g);
ok = ok && allocate_geometry(g);
ok = allocate_geometry(g);
if (!ok)
{
free_grid(g);