Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 451220 - nsIMemory.Free is easier to use than NS_Free
Summary: nsIMemory.Free is easier to use than NS_Free
Status: RESOLVED WONTFIX
Alias: None
Product: Platform
Classification: Eclipse Project
Component: SWT (show other bugs)
Version: 4.5   Edit
Hardware: PC Windows 7
: P3 enhancement (vote)
Target Milestone: ---   Edit
Assignee: Platform-SWT-Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-11-12 12:58 EST by Neil Rashbrook CLA
Modified: 2015-04-01 08:22 EDT (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Neil Rashbrook CLA 2014-11-12 12:58:25 EST
The code that tries to call NS_Free could be simplified by ignoring NS_Free and just calling nsMemory.Free which always does the right thing.
Comment 1 Lakshmi P Shanmugam CLA 2014-12-24 05:53:02 EST
The patch (https://git.eclipse.org/r/#/c/36354/) causes a crash with the test case at -- https://bugs.eclipse.org/bugs/show_bug.cgi?id=316252#c3
I believe we should not modify the working & tested code here.
Comment 2 Neil Rashbrook CLA 2014-12-24 14:00:08 EST
(In reply to Lakshmi Shanmugam from comment #1)
> The patch (https://git.eclipse.org/r/#/c/36354/) causes a crash with the
> test case at -- https://bugs.eclipse.org/bugs/show_bug.cgi?id=316252#c3
> I believe we should not modify the working & tested code here.

I'll take your word for it, but it didn't crash when I tried it.
Comment 3 Neil Rashbrook CLA 2015-04-01 08:22:00 EDT
Well, Firefox 39 will be removing nsIMemory, which is annoying, since it's so much easier to use than NS_Free.