diff options
author | Mark Spruiell <mes@zeroc.com> | 2015-12-17 11:45:27 -0800 |
---|---|---|
committer | Mark Spruiell <mes@zeroc.com> | 2015-12-17 11:45:27 -0800 |
commit | 884e2be89b0cd997f372c59f05bf05a9a5372b60 (patch) | |
tree | 53d2123abf22042f827d0e83b6093cea038c3b3a /java/src | |
parent | Merge branch '3.6' (diff) | |
download | ice-884e2be89b0cd997f372c59f05bf05a9a5372b60.tar.bz2 ice-884e2be89b0cd997f372c59f05bf05a9a5372b60.tar.xz ice-884e2be89b0cd997f372c59f05bf05a9a5372b60.zip |
Fixes for Bluetooth plug-ins.
Updates to testsuite to support Bluetooth and remote servers.
Diffstat (limited to 'java/src')
-rw-r--r-- | java/src/Ice/src/main/java/IceInternal/PropertyNames.java | 3 | ||||
-rw-r--r-- | java/src/IceBT/src/main/java/IceBT/EndpointI.java | 32 |
2 files changed, 26 insertions, 9 deletions
diff --git a/java/src/Ice/src/main/java/IceInternal/PropertyNames.java b/java/src/Ice/src/main/java/IceInternal/PropertyNames.java index 147a6adc6b1..d689997225a 100644 --- a/java/src/Ice/src/main/java/IceInternal/PropertyNames.java +++ b/java/src/Ice/src/main/java/IceInternal/PropertyNames.java @@ -6,7 +6,7 @@ // ICE_LICENSE file included in this distribution. // // ********************************************************************** -// Generated by makeprops.py from file ../config/PropertyNames.xml, Mon Nov 9 08:34:24 2015 +// Generated by makeprops.py from file ../config/PropertyNames.xml, Tue Nov 24 08:50:30 2015 // IMPORTANT: Do not edit this file -- any edits made here will be lost! @@ -1021,7 +1021,6 @@ public final class PropertyNames public static final Property IceBTProps[] = { - new Property("IceBT\\.DefaultAddress", false, null), new Property("IceBT\\.RcvSize", false, null), new Property("IceBT\\.SndSize", false, null), null diff --git a/java/src/IceBT/src/main/java/IceBT/EndpointI.java b/java/src/IceBT/src/main/java/IceBT/EndpointI.java index 4c18fbdb687..156918de45d 100644 --- a/java/src/IceBT/src/main/java/IceBT/EndpointI.java +++ b/java/src/IceBT/src/main/java/IceBT/EndpointI.java @@ -276,13 +276,22 @@ final class EndpointI extends IceInternal.EndpointI if(_addr.length() == 0) { - _addr = _instance.properties().getProperty("IceBT.DefaultAddress"); + _addr = _instance.defaultHost(); } - if(!oaEndpoint && _addr.length() == 0) + if(_addr.length() == 0 || _addr.equals("*")) { - throw new Ice.EndpointParseException( - "a device address must be specified using the -a option or IceBT.DefaultAddress"); + if(oaEndpoint) + { + // + // Ignore a missing address, we always use the default adapter anyway. + // + } + else + { + throw new Ice.EndpointParseException( + "a device address must be specified using the -a option or Ice.Default.Host"); + } } if(_name.length() == 0) @@ -292,7 +301,17 @@ final class EndpointI extends IceInternal.EndpointI if(_uuid == null) { - throw new Ice.EndpointParseException("a UUID must be specified using the -u option"); + if(oaEndpoint) + { + // + // Generate a UUID for object adapters that don't specify one. + // + _uuid = UUID.randomUUID(); + } + else + { + throw new Ice.EndpointParseException("a UUID must be specified using the -u option"); + } } hashInit(); @@ -408,7 +427,7 @@ final class EndpointI extends IceInternal.EndpointI { throw new Ice.EndpointParseException("no argument provided for -a option in endpoint " + endpoint); } - if(!BluetoothAdapter.checkBluetoothAddress(argument.toUpperCase())) + if(!argument.equals("*") && !BluetoothAdapter.checkBluetoothAddress(argument.toUpperCase())) { throw new Ice.EndpointParseException("invalid address provided for -a option in endpoint " + endpoint); } @@ -512,7 +531,6 @@ final class EndpointI extends IceInternal.EndpointI int h = 5381; h = IceInternal.HashUtil.hashAdd(h, _addr); h = IceInternal.HashUtil.hashAdd(h, _uuid.toString()); - h = IceInternal.HashUtil.hashAdd(h, _channel); h = IceInternal.HashUtil.hashAdd(h, _timeout); h = IceInternal.HashUtil.hashAdd(h, _connectionId); h = IceInternal.HashUtil.hashAdd(h, _compress); |