Skip to content

Commit

Permalink
Cleanup for PR comments
Browse files Browse the repository at this point in the history
  • Loading branch information
robstryker committed May 18, 2016
1 parent 740ad9d commit be32d05
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,8 @@ public DefaultKeySet() {
SHUTDOWN_COMMAND = "org.jboss.ide.eclipse.as.core.launch.SHUTDOWN_COMMAND";//$NON-NLS-1$
DETECT_STARTUP_COMMAND = "org.jboss.ide.eclipse.as.core.launch.DETECT_STARTUP_COMMAND";//$NON-NLS-1$
DETECT_SHUTDOWN_COMMAND = "org.jboss.ide.eclipse.as.core.launch.DETECT_SHUTDOWN_COMMAND";//$NON-NLS-1$
DEBUG_STARTUP_COMMAND = null; // not relevant
// not relevant for the default (ie local) keyset. Local keyset does not store a debug command
DEBUG_STARTUP_COMMAND = null;
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -158,7 +158,7 @@ protected String getLaunchCommand(JBossServer jbossServer) throws CoreException
String programArguments = getLaunchProgramArgs();
String vmArguments = getLaunchVMArgs();
String jar = getJar(jbossServer.getServer());
String command = "java " + vmArguments + " -jar " + jar + " " + IJBossRuntimeConstants.SPACE + programArguments + "&";
String command = "java " + vmArguments + " -jar " + jar + IJBossRuntimeConstants.SPACE + programArguments + "&";
return command;
}

Expand All @@ -168,7 +168,7 @@ protected String getLaunchDebugCommand(JBossServer jbossServer) throws CoreExcep
String jar = getJar(jbossServer.getServer());
String debugPort = getDebugPort();
String debugArgs = "-Xrunjdwp:transport=dt_socket,server=y,suspend=n,address=" + debugPort + " -Xdebug ";
String command = "java " + debugArgs + vmArguments + " -jar " + jar + " " + IJBossRuntimeConstants.SPACE + programArguments + "&";
String command = "java " + debugArgs + vmArguments + " -jar " + jar + IJBossRuntimeConstants.SPACE + programArguments + "&";
return command;
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -151,6 +151,8 @@ protected int getDebugPort(IServer server) {
} catch(NumberFormatException nfe) {
port = RSEJbossLaunchConstants.DEFAULT_DEBUG_PORT;
}
if( port < 1 )
port = RSEJbossLaunchConstants.DEFAULT_DEBUG_PORT;
return port;
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,10 @@ public void verifyText(VerifyEvent e) {
return;
try {
Integer i = Integer.parseInt(e.text);
if( i.intValue() == 0 ) {
// do not allow port 0
e.doit = false;
}
} catch( NumberFormatException nfe ) {
e.doit = false;
}
Expand All @@ -95,7 +99,7 @@ public void widgetDefaultSelected(SelectionEvent e) {
portText.addModifyListener(new ModifyListener() {
public void modifyText(ModifyEvent e) {
ServerWorkingCopyPropertyTextCommand command = new ServerWorkingCopyPropertyTextCommand(
helper.getWorkingCopy(), "Enable debugging", portText, portText.getText(),
helper.getWorkingCopy(), "Change Debug Port", portText, portText.getText(),
RSEJbossLaunchConstants.DEBUG_PORT, new Integer(RSEJbossLaunchConstants.DEFAULT_DEBUG_PORT).toString(), this);
section.execute(command);
}
Expand Down

0 comments on commit be32d05

Please sign in to comment.