← Back to team overview

dolfin team mailing list archive

Re: [HG DOLFIN] Fix very hard to find bug in dolfin_utils.

 



Anders Logg wrote:
On Sat, May 16, 2009 at 05:08:18PM +0200, DOLFIN wrote:

One or more new changesets pushed to the primary dolfin repository.
A short summary of the last three changesets is included below.

changeset:   6163:dff00dceec7cb1e9a8c5b89aa33519d555315ba5
tag:         tip
user:        "Garth N. Wells <gnw20@xxxxxxxxx>"
date:        Sat May 16 16:06:30 2009 +0100
Fix very hard to find bug in dolfin_utils.

--- a/site-packages/dolfin_utils/wrappers/functionspace.py      Fri
May 15 15:21:10 2009 +0200
+++ b/site-packages/dolfin_utils/wrappers/functionspace.py      Sat
May 16 16:06:30 2009 +0100
@@ -46,7 +46,7 @@
 //  }
// - virtual ~%(classname)s()
+  ~%(classname)s()
   {
   }

Was it just this?

Yes.

I started looking at the bug but couldn't figure out
what was wrong. I thought it was always safe to make a destructor
virtual.


I didn't know either that it was a problem. I reduced the problem to

   const FunctionSpace* V = new CoefficientSpace_f;
   delete V;

which failed when the destructor was virtual (there were no other virtual member functions).

Garth

Anyway, seems to work now.



------------------------------------------------------------------------

_______________________________________________
DOLFIN-dev mailing list
DOLFIN-dev@xxxxxxxxxx
http://www.fenics.org/mailman/listinfo/dolfin-dev




Follow ups

References