Program: 79407
Project: 79407
Buggy source:
protected JcloudsSshMachineLocation createJcloudsSshMachineLocation(ComputeService computeService,NodeMetadata node,String vmHostname,Optional<HostAndPort> sshHostAndPort,ConfigBag setup) throws IOException {
  Map<?,?> sshConfig=extractSshConfig(setup,node);
  String nodeAvailabilityZone=extractAvailabilityZone(setup,node);
  String nodeRegion=extractRegion(setup,node);
  if (nodeRegion == null) {
    nodeRegion=extractProvider(setup,node);
  }
  String address=sshHostAndPort.isPresent() ? sshHostAndPort.get().getHostText() : vmHostname;
  try {
    Networking.getInetAddressWithFixedName(address);
  }
 catch (  Exception e) {
    Exceptions.propagateIfFatal(e);
    LOG.debug("String_Node_Str" + address + "String_Node_Str"+ vmHostname+ "String_Node_Str"+ setup.getDescription()+ "String_Node_Str"+ node+ "String_Node_Str");
    if (computeService == null)     throw Exceptions.propagate(e);
    address=JcloudsUtil.getFirstReachableAddress(computeService.getContext(),node);
  }
  if (LOG.isDebugEnabled())   LOG.debug("String_Node_Str",new Object[]{getUser(setup),address,Entities.sanitize(sshConfig),sshHostAndPort,setup.getDescription(),node});
  if (isManaged()) {
    return getManagementContext().getLocationManager().createLocation(LocationSpec.create(JcloudsSshMachineLocation.class).configure("String_Node_Str",vmHostname).configure("String_Node_Str",address).configure(JcloudsSshMachineLocation.SSH_PORT,sshHostAndPort.isPresent() ? sshHostAndPort.get().getPort() : node.getLoginPort()).configure("String_Node_Str",getUser(setup)).configure(sshConfig).configure("String_Node_Str",sshConfig).configure("String_Node_Str",this).configure("String_Node_Str",node).configureIfNotNull(CLOUD_AVAILABILITY_ZONE_ID,nodeAvailabilityZone).configureIfNotNull(CLOUD_REGION_ID,nodeRegion).configure(CALLER_CONTEXT,setup.get(CALLER_CONTEXT)).configure(SshMachineLocation.DETECT_MACHINE_DETAILS,setup.get(SshMachineLocation.DETECT_MACHINE_DETAILS)).configure(SshMachineLocation.SCRIPT_DIR,setup.get(SshMachineLocation.SCRIPT_DIR)).configureIfNotNull(USE_PORT_FORWARDING,setup.get(USE_PORT_FORWARDING)).configureIfNotNull(PORT_FORWARDER,setup.get(PORT_FORWARDER)).configureIfNotNull(PORT_FORWARDING_MANAGER,setup.get(PORT_FORWARDING_MANAGER)));
  }
 else {
    LOG.warn("String_Node_Str" + this + "String_Node_Str");
    return new JcloudsSshMachineLocation(MutableMap.builder().put("String_Node_Str",vmHostname).put("String_Node_Str",address).put("String_Node_Str",sshHostAndPort.isPresent() ? sshHostAndPort.get().getPort() : node.getLoginPort()).put("String_Node_Str",getUser(setup)).putAll(sshConfig).put("String_Node_Str",sshConfig).put("String_Node_Str",setup.get(CALLER_CONTEXT)).putIfNotNull(CLOUD_AVAILABILITY_ZONE_ID.getName(),nodeAvailabilityZone).putIfNotNull(CLOUD_REGION_ID.getName(),nodeRegion).put(USE_PORT_FORWARDING,setup.get(USE_PORT_FORWARDING)).put(PORT_FORWARDER,setup.get(PORT_FORWARDER)).put(PORT_FORWARDING_MANAGER,setup.get(PORT_FORWARDING_MANAGER)).build(),this,node);
  }
}

Fixed version (ground truth):
protected JcloudsSshMachineLocation createJcloudsSshMachineLocation(ComputeService computeService,NodeMetadata node,String vmHostname,Optional<HostAndPort> sshHostAndPort,ConfigBag setup) throws IOException {
  Map<?,?> sshConfig=extractSshConfig(setup,node);
  String nodeAvailabilityZone=extractAvailabilityZone(setup,node);
  String nodeRegion=extractRegion(setup,node);
  if (nodeRegion == null) {
    nodeRegion=extractProvider(setup,node);
  }
  String address=sshHostAndPort.isPresent() ? sshHostAndPort.get().getHostText() : vmHostname;
  try {
    Networking.getInetAddressWithFixedName(address);
  }
 catch (  Exception e) {
    Exceptions.propagateIfFatal(e);
    LOG.debug("String_Node_Str" + address + "String_Node_Str"+ vmHostname+ "String_Node_Str"+ setup.getDescription()+ "String_Node_Str"+ node+ "String_Node_Str");
    if (computeService == null)     throw Exceptions.propagate(e);
    address=JcloudsUtil.getFirstReachableAddress(computeService.getContext(),node);
  }
  if (LOG.isDebugEnabled())   LOG.debug("String_Node_Str",new Object[]{getUser(setup),address,Entities.sanitize(sshConfig),sshHostAndPort,setup.getDescription(),node});
  if (isManaged()) {
    return getManagementContext().getLocationManager().createLocation(LocationSpec.create(JcloudsSshMachineLocation.class).configure("String_Node_Str",vmHostname).configure("String_Node_Str",address).configure(JcloudsSshMachineLocation.SSH_PORT,sshHostAndPort.isPresent() ? sshHostAndPort.get().getPort() : node.getLoginPort()).configure("String_Node_Str",getUser(setup)).configure(sshConfig).configure("String_Node_Str",sshConfig).configure("String_Node_Str",this).configure("String_Node_Str",node).configureIfNotNull(CLOUD_AVAILABILITY_ZONE_ID,nodeAvailabilityZone).configureIfNotNull(CLOUD_REGION_ID,nodeRegion).configure(CALLER_CONTEXT,setup.get(CALLER_CONTEXT)).configure(SshMachineLocation.DETECT_MACHINE_DETAILS,setup.get(SshMachineLocation.DETECT_MACHINE_DETAILS)).configureIfNotNull(SshMachineLocation.SCRIPT_DIR,setup.get(SshMachineLocation.SCRIPT_DIR)).configureIfNotNull(USE_PORT_FORWARDING,setup.get(USE_PORT_FORWARDING)).configureIfNotNull(PORT_FORWARDER,setup.get(PORT_FORWARDER)).configureIfNotNull(PORT_FORWARDING_MANAGER,setup.get(PORT_FORWARDING_MANAGER)));
  }
 else {
    LOG.warn("String_Node_Str" + this + "String_Node_Str");
    return new JcloudsSshMachineLocation(MutableMap.builder().put("String_Node_Str",vmHostname).put("String_Node_Str",address).put("String_Node_Str",sshHostAndPort.isPresent() ? sshHostAndPort.get().getPort() : node.getLoginPort()).put("String_Node_Str",getUser(setup)).putAll(sshConfig).put("String_Node_Str",sshConfig).put("String_Node_Str",setup.get(CALLER_CONTEXT)).putIfNotNull(CLOUD_AVAILABILITY_ZONE_ID.getName(),nodeAvailabilityZone).putIfNotNull(CLOUD_REGION_ID.getName(),nodeRegion).put(USE_PORT_FORWARDING,setup.get(USE_PORT_FORWARDING)).put(PORT_FORWARDER,setup.get(PORT_FORWARDER)).put(PORT_FORWARDING_MANAGER,setup.get(PORT_FORWARDING_MANAGER)).build(),this,node);
  }
}