sonar-runner.bat fails when java.exe is found in the path but contains a space

Details

• Type: Bug
• Status: Closed
• Priority: Major
• Resolution: Fixed
• Affects Version/s: None
• Fix Version/s:
• Labels:
None
• Environment:
Windows
• Number of attachments :
1

Description

If java.exe is found in the path it is not quoted and so fails when it comes time to run.

As java installed to "c:\program files\..." by default, I can see this affecting the majority of windows users.

Attachments

1. SONARPLUGINS-1921.patch
0.4 kB

Activity

Hide

Attached patch for this issue, which quotes JAVA_EXEC if it's found in the path.

Patch affects:

http://svn.codehaus.org/sonar-plugins/trunk/sonar-runner/src/main/assembly/bin/sonar-runner.bat

Show
Richad Szalay added a comment - Attached patch for this issue, which quotes JAVA_EXEC if it's found in the path. Patch affects: http://svn.codehaus.org/sonar-plugins/trunk/sonar-runner/src/main/assembly/bin/sonar-runner.bat
Hide
Fabrice Bellingard added a comment -

Patch applied.

Note that this bug does not occur on Windows 7 (and I guess Vista as well). I had to use a VM with Windows XP to be able to reproduce it and then verify the patch.

Show
Fabrice Bellingard added a comment - Patch applied. Note that this bug does not occur on Windows 7 (and I guess Vista as well). I had to use a VM with Windows XP to be able to reproduce it and then verify the patch.
Hide
Freddy Mallet added a comment -

Manually tested !

Show
Freddy Mallet added a comment - Manually tested !

People

• Assignee:
Fabrice Bellingard
Reporter:
Fabrice Bellingard