Memory Leak from NStylePreviewEditor


Author
Message
Mark Demory
Mark Demory
Forum Newbie (1 reputation)Forum Newbie (1 reputation)Forum Newbie (1 reputation)Forum Newbie (1 reputation)Forum Newbie (1 reputation)Forum Newbie (1 reputation)Forum Newbie (1 reputation)Forum Newbie (1 reputation)Forum Newbie (1 reputation)
Group: Forum Members
Posts: 1, Visits: 1

The Text Style editor creates a new instance of class NStylePreviewEditor every time it is opened.  These objects never get cleaned up, in the example code Nevron provided with the following version:
    .NET Vision 2010.1 for VS2010 version 11.1.17.12

The NStylePreviewEditor is never properly disposed, causing a catastrophic memory leak.  We have users who need to open this editor dozens of times on one Nevron document, which causes our application to fail because all memory is consumed.

Here is the code we use to allow the user to change, for example, the default font size for a Nevron document or object:

    result = NTextStyleTypeEditor.Edit(Me.Document.Style.TextStyle, newTextStyle)


We are using VB.Net for .NET 4.0.

We used sos.dll and the following command to discover that every time a user opens the Text Style editor a new instance of this object is created, and never released:

    !dumpheap -type Nevron.Editors.NStylePreviewEditor


Nevron Support
Nevron Support
Supreme Being (4.5K reputation)Supreme Being (4.5K reputation)Supreme Being (4.5K reputation)Supreme Being (4.5K reputation)Supreme Being (4.5K reputation)Supreme Being (4.5K reputation)Supreme Being (4.5K reputation)Supreme Being (4.5K reputation)Supreme Being (4.5K reputation)
Group: Administrators
Posts: 3.1K, Visits: 4.2K

Hello Mark,
Thank you for pointing out this problem, it has been fixed and the fix will be included with the next version which is expected in the next two weeks.

Please excuse us for any inconvenience.



Best Regards,
Nevron Support Team


GO

Merge Selected

Merge into selected topic...



Merge into merge target...



Merge into a specific topic ID...




Similar Topics

Reading This Topic

Login

Explore
Messages
Mentions
Search