Merge remote-tracking branch

'origin/GP-2-dragonmacher-err-log-dialog-patch-2' into patch
(Closes #4251)
This commit is contained in:
Ryan Kurtz 2022-05-16 11:17:40 -04:00
commit 8971a72e9b

View file

@ -18,8 +18,6 @@ package docking;
import java.awt.*;
import java.awt.event.ComponentAdapter;
import java.awt.event.ComponentEvent;
import java.net.InetAddress;
import java.net.UnknownHostException;
import java.util.*;
import java.util.List;
@ -119,8 +117,7 @@ public class ErrLogDialog extends AbstractErrDialog {
String hostname = getHostnameString();
if (hostname != null) {
sb.append("Workstation: ");
sb.append(getHostname());
sb.append(hostname);
sb.append(EOL);
}
return sb.toString();
@ -146,18 +143,6 @@ public class ErrLogDialog extends AbstractErrDialog {
return "Workstation: " + name;
}
private Object getHostname() {
String hostname = "<unknown>";
try {
InetAddress addr = InetAddress.getLocalHost();
hostname = addr.getCanonicalHostName();
}
catch (UnknownHostException e) {
// ignore
}
return hostname;
}
public static void setErrorReporter(ErrorReporter errorReporter) {
ErrLogDialog.errorReporter = errorReporter;
}