This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 227022 - Null pointer exception when installing created installer bundle on Mac Os X
Summary: Null pointer exception when installing created installer bundle on Mac Os X
Status: RESOLVED WORKSFORME
Alias: None
Product: apisupport
Classification: Unclassified
Component: NBI (show other bugs)
Version: 7.3
Hardware: PC Mac OS X
: P3 normal (vote)
Assignee: Libor Fischmeistr
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-03-05 09:35 UTC by reyez
Modified: 2014-07-21 12:30 UTC (History)
4 users (show)

See Also:
Issue Type: DEFECT
Exception Reporter: 227022


Attachments
jpg (24.25 KB, patch)
2013-10-22 12:03 UTC, fawzalnz8a25
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description reyez 2013-03-05 09:35:33 UTC
we are just moving our Netbeans RCP app to a Maven based build.

We are creating an installer from our Netbeans RCP application. The building of the installer itself works without any problems.

However, when we are trying to install the generated installer we are getting the attached exception (from .netbeans-installer/log).

The error occurs in Netbeans 70, 71 and 73 on Mac OS X.
The installer starts, installs and then does a rollback (all in one run).


[2013-03-04 14:57:32.478]:         ... running installation logic
[2013-03-04 14:57:32.479]:         java.lang.NullPointerException
[2013-03-04 14:57:32.479]:         at
org.netbeans.installer.utils.StreamUtils.transferData(StreamUtils.java:67)
[2013-03-04 14:57:32.479]:         at
org.netbeans.installer.utils.FileUtils.writeFile(FileUtils.java:215)
[2013-03-04 14:57:32.479]:         at
org.netbeans.installer.utils.FileUtils.writeFile(FileUtils.java:188)
[2013-03-04 14:57:32.479]:         at
org.mycompany.ConfigurationLogic.install(ConfigurationLogic.java:106)
[2013-03-04 14:57:32.480]:         at
org.netbeans.installer.product.components.Product.install(Product.java:358)
[2013-03-04 14:57:32.480]:         at
org.netbeans.installer.wizard.components.actions.InstallAction.execute(InstallAction.java:155)
[2013-03-04 14:57:32.480]:         at
org.netbeans.installer.wizard.components.WizardAction$1.run(WizardAction.java:123)
[2013-03-04 14:57:32.481]:         Start rollback of application
5.0-beta-5(application/1.0.0.0.0)

Any hints appreciated... Thanks!
Comment 1 Libor Fischmeistr 2013-03-06 11:20:52 UTC
Just to summary. You were using ant before and now you've started with maven. When using ant, there were no problem with installer and after migration to maven, this NPE has appeared. Am I right?

Thanks in advance for the answer.
Comment 2 reyez 2013-03-06 11:44:04 UTC
(In reply to comment #1)
> Just to summary. You were using ant before and now you've started with maven.
> When using ant, there were no problem with installer and after migration to
> maven, this NPE has appeared. Am I right?
Yes.

Thanks!
Comment 3 reyez 2013-03-06 11:48:01 UTC
Or even more precise I build the original installer via the Netbeans IDE (what then runs ant I guess).
Thanks for looking into the issue!
Raphael
Comment 4 reyez 2013-03-07 15:39:31 UTC
Just played around a bit more...

Seems the NPE is coming from there:
<userSettings>
<nbi.dock.icon.file>src/main/resources/applicationIcon.icns</nbi.dock.icon.file>
</userSettings>

If I am removing nbi.dock.icon.file the installer works. When I am setting the nbi.dock.icon.file the Mac OS X installer no longer works.

Win and Linux installers work fine.

After looking in the source it seems that the problem comes from:
ConfigurationLogic.java
    
public static final String ICON_MACOSX =
            ResourceUtils.getString(ConfigurationLogic.class, "CL.app.name") + ".icns"; // NOI18N

But I am no expert - to what should ResourceUtils.getString(ConfigurationLogic.class, "CL.app.name") + ".icns" usually resolve to?

Any hints appreciated...
Comment 5 fawzalnz8a25 2013-10-22 12:03:38 UTC
Created attachment 141404 [details]
jpg

hi all whats ap
Comment 6 Libor Fischmeistr 2014-07-21 12:30:35 UTC
I think it's not actual bug. If the exception will appear in the newer NB version, please reopen.