Opened 4 years ago

Closed 3 years ago

#14618 closed Bug (expired)

Memory leak happening in CKEditor when navigating to different view

Reported by: Kunal Garg Owned by:
Priority: Normal Milestone:
Component: General Version: 4.5.9
Keywords: memory-leak Cc:

Description

Steps to reproduce

  1. Use CKEditor.replace on textArea
  2. Now navigate to different view. This destroy the editor.
  3. Recreate the editor with CKEditor.replace

Expected result

The objects allocated in the first iteration should be fred

Actual result

The objects are still there and keep on piling on repeating step 2 and 3

Other details (browser, OS, CKEditor version, installed plugins)

Attachments (1)

Capture.PNG (20.8 KB) - added by Kunal Garg 4 years ago.
Showing memory objects bound to the FormElement

Download all attachments as: .zip

Change History (5)

Changed 4 years ago by Kunal Garg

Attachment: Capture.PNG added

Showing memory objects bound to the FormElement

comment:1 Changed 4 years ago by Kunal Garg

I debugged the issue and it is happening because of following code: form.$.submit = CKEDITOR.tools.override( form.$.submit, function( originalSubmit ) {

return function() {

onSubmit();

For IE, the DOM submit function is not a function, so we need third check. if ( originalSubmit.apply )

originalSubmit.apply( this );

else

originalSubmit();

};

});

It works fine after I set the form.$.submit = null; in destroy.

comment:2 Changed 4 years ago by Kunal Garg

The attachment shows hw objects are retained by the submit of form element

comment:3 Changed 4 years ago by Tade0

Status: newpending

I'm having trouble reproducing this one. Could you provide a heap snapshot that demonstrates this issue?

comment:4 Changed 3 years ago by Jakub Ś

Resolution: expired
Status: pendingclosed
Note: See TracTickets for help on using tickets.
© 2003 – 2019 CKSource – Frederico Knabben. All rights reserved. | Terms of use | Privacy policy