summaryrefslogtreecommitdiff
path: root/java/src
diff options
context:
space:
mode:
authorJose <jose@zeroc.com>2013-02-18 12:38:33 +0100
committerJose <jose@zeroc.com>2013-02-18 12:38:33 +0100
commitd8864f482597f56adcf24bd4e19329f3794a2d2e (patch)
treeae6aa2edd79b1b86d72956847ab5bbf662b76e12 /java/src
parentICE-5158 Added metadata printout to slice2confluence for enumerations in enums (diff)
downloadice-d8864f482597f56adcf24bd4e19329f3794a2d2e.tar.bz2
ice-d8864f482597f56adcf24bd4e19329f3794a2d2e.tar.xz
ice-d8864f482597f56adcf24bd4e19329f3794a2d2e.zip
Fixed (ICE-5245) - IceGridGUI connection dialog should add quotes to the hostname
Diffstat (limited to 'java/src')
-rw-r--r--java/src/IceGridGUI/Coordinator.java14
-rw-r--r--java/src/IceGridGUI/SessionKeeper.java8
2 files changed, 19 insertions, 3 deletions
diff --git a/java/src/IceGridGUI/Coordinator.java b/java/src/IceGridGUI/Coordinator.java
index edc20274d33..b74bdc52d19 100644
--- a/java/src/IceGridGUI/Coordinator.java
+++ b/java/src/IceGridGUI/Coordinator.java
@@ -1766,7 +1766,12 @@ public class Coordinator
{
str += "tcp";
}
- str += " -h " + info.getHost() + " -p " + info.getPort();
+ String host = info.getHost();
+ if(host.indexOf('"') == -1)
+ {
+ host = "\"" + host + "\"";
+ }
+ str += " -h " + host + " -p " + info.getPort();
}
else
{
@@ -1987,7 +1992,12 @@ public class Coordinator
{
str += "tcp";
}
- str += " -h " + info.getHost() + " -p " + info.getPort();
+ String host = info.getHost();
+ if(host.indexOf('"') == -1)
+ {
+ host = "\"" + host + "\"";
+ }
+ str += " -h " + host + " -p " + info.getPort();
}
else
{
diff --git a/java/src/IceGridGUI/SessionKeeper.java b/java/src/IceGridGUI/SessionKeeper.java
index f1b78e1b6b9..12c4a2df2b7 100644
--- a/java/src/IceGridGUI/SessionKeeper.java
+++ b/java/src/IceGridGUI/SessionKeeper.java
@@ -543,7 +543,13 @@ public class SessionKeeper
{
name += "tcp";
}
- name += " -h " + getHost() + " -p " + Integer.toString(getPort());
+ String host = getHost();
+ if(host.indexOf('"') == -1)
+ {
+ host = "\"" + host + "\"";
+ }
+
+ name += " -h " + host + " -p " + Integer.toString(getPort());
}
else
{