Hi,
On Thu, Jul 19, 2012 at 2:40 AM, Florian Beck <Flo.44 at gmx.de> wrote: >> In the debugger is the adress of my vector at the beginning and the end >> the same, but if I look inside the vector the adress of ops, map and >data >> are 0x0 after I call the function VecDuplicate(). Is there a function to >> synchronize the vectors before I destroy them? > > >Sounds like a reference-counting bug. The most common cause is basically > >Vec X,Y; >VecCreate(comm,&X); >... >Y = X; >... >VecDestroy(&X); >VecDestroy(&Y); > >(perhaps spread across multiple functions, and perhaps with a reference >obtained through a function that does not give you an "ownership share" by >incrementing reference count). > >You can use "watch -l X->hdr.refct" in recent gdb to follow all the >locations where reference count was changed (this includes the library), >if >you need a heavyweight methodology for tracking down the error. > I have looked for the counting bug, but I haven't found anything because my gdb crashes. Is it not possible to restore the addresses ops, map and data? I think it's possible to get values and from the vectors, so why shouldn't it possible to destroy them? Or is it possible to destroy the Vectors manually?
