On Fri, Apr 8, 2011 at 11:13 PM, Jon Cruz <jon@...18...> wrote:

On Apr 8, 2011, at 6:48 PM, Krzysztof Kosiński wrote:

> This looks like uninitialized memory in NRStyle. I added explicit NULL
> initializers in rev. 9588, see whether it fixes the crash.


Well, since we're C++ we should be using 0 instead of NULL.  :-)

But more importantly, this is exactly the sort of issue that Valgrind is very good at spotting and pointing out.

When problems like this (subtle corruptions or crashing) are hit, running under valgrind should be a first step. It will generally catch a problem when it first occurs, not later on after it has cascaded enough to actually cause a crash, etc.

If anyone needs more detail on the wiki for this, let me know. Also drop on in to IRC to hash it out (that really helps).

Krzysztof,

It appears that the new renderer doesn't release memory on zooming operations. Without any modifications to the document, just zooming in and out a number of times shows memory growth and memory that isn't released. If it's known and expected, okay, but it's just an observation I figured I would point out. The document I sent you off-list is a good test file for this behavior btw. (a follow-up to a valgrind reply seemed like it was a relevant place to comment)

Cheers,
Josh