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 29875

Summary: Post install hook doesn't work with a space in userdir path
Product: platform Reporter: Martin Ryzl <mryzl>
Component: AutoupdateAssignee: Petr Hrebejk <phrebejk>
Status: CLOSED FIXED    
Severity: blocker Keywords: SPACE_IN_PATH
Priority: P2    
Version: -S1S-   
Hardware: PC   
OS: Windows ME/2000   
Issue Type: TASK Exception Reporter:
Attachments: Suggested patch

Description Martin Ryzl 2003-01-08 15:32:03 UTC
Autoupdate module allows to execute a post install
code. The code is specified in
main/main.properties file in the nbm. The command
consists of:
- java process - created by autoupdate module
- classpath - additioanl classpath may be
specified by nbm
- nbm parameters - specified by the nbm
- main class - specified by the nbm

There are keywords that can be replaced by the
module, for example %IDE_USER%. It is a question
whether it is nbm author's responsibility to quote
keywords, I think that it is.

However, the problem is with classpath - first
item of classpath is created by au module and _NOT
QUOTED_. So, if
userdir contains a space, the execution fails.

Tested on S1S 4.1, probably affects all versions
of NB and S1S.
Comment 1 Martin Ryzl 2003-01-08 16:02:44 UTC
Created attachment 8474 [details]
Suggested patch
Comment 2 Martin Ryzl 2003-01-08 16:04:58 UTC
Attached path quotes only java process and first item in the
classpath. User parameters (those specified in main.properties) must
be quoted by nbm author. If this model is OK, it should be correctly
documented in the autoupdate module documentation.
Comment 3 akemr 2003-01-09 09:18:09 UTC
Thanks, Martin. Fixed in trunk.

Fix quotes only java process and whole classpath.
Documentation - I added your note to #26730.
Comment 4 Antonin Nebuzelsky 2003-02-25 18:35:03 UTC
This is also fixed and released in a patch for S1S4u1.
Comment 5 Martin Ryzl 2003-07-08 14:42:57 UTC
verified