netbeans-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From frederic <>
Subject Bug in Netbeans for MacOS
Date Tue, 01 May 2018 11:24:43 GMT
Dear all, 

I have found a bug in Netbeans on MacOS which makes the applications
crash on MacOS. I would like to know if it is possible to fix it in
Netbeans 8.0.1 or at least to make sure it is not in Netbeans 8.2.

The bug : 

I'm using Netbeans 8.0.1 for Ancestris. There seems to be a conflicting
thread in that compromises the removal of lookup

Therefore, if an updateLookup runs in the application, the following
thread is activated which itself runs an updateLookup.

The application ends up multiplying the number of listeners up to
several tens of thousands and crashes on Mac.

Here is the code with the bug: (in in package

       if (Utilities.getOperatingSystem() == Utilities.OS_MAC) {
           //Show a "save dot" in the close button if a modified file
           //being edited
           //Show the icon of the edited file in the window titlebar
           //other mac apps
           saveResult = Utilities.actionsGlobalContext().lookupResult
           dobResult = Utilities.actionsGlobalContext().lookupResult
           if( null != saveResult && null != dobResult ) {
               saveListener = new LookupListener() {
                   public void resultChanged(final LookupEvent ev) {
              new Runnable() {

                           public void run() {


The " updateMacDocumentProperties(ev)" includes : 
- saveResult.allItems()
- dobResult.allItems()
which trigger an updateLookup as well, creating two threads updating
the same lookups (removeListener, addListener).

The fix:

I would be ok to just replace :

      "Utilities.getOperatingSystem() == Utilities.OS_MAC"


     "Utilities.getOperatingSystem() == Utilities.OS_MAC & false"

because I do not think we need this on Mac in the Ancestris application
at least.

Can someone recompile the package with this fix and send it back to me
? Or else can someone help me fix it myself localy (I do not have the
code to recompile this package) ?

Many thanks in advance if it can be done.

Best regards,

View raw message