X-Git-Url: https://git.nmode.ca/signal-cli/blobdiff_plain/541ac777bcbd6590fa759d0a026aa4b195b8411d..73d44ba3fee81e5a19f1055bd90366e37f0341ec:/src/main/java/org/asamk/signal/dbus/DbusSignalControlImpl.java diff --git a/src/main/java/org/asamk/signal/dbus/DbusSignalControlImpl.java b/src/main/java/org/asamk/signal/dbus/DbusSignalControlImpl.java index a11d8fa0..2d211444 100644 --- a/src/main/java/org/asamk/signal/dbus/DbusSignalControlImpl.java +++ b/src/main/java/org/asamk/signal/dbus/DbusSignalControlImpl.java @@ -96,14 +96,16 @@ public class DbusSignalControlImpl implements org.asamk.SignalControl { public String link(final String newDeviceName) throws Error.Failure { try { final URI deviceLinkUri = c.getNewProvisioningDeviceLinkUri(); - new Thread(() -> { + final var thread = new Thread(() -> { final ProvisioningManager provisioningManager = c.getProvisioningManagerFor(deviceLinkUri); try { provisioningManager.finishDeviceLink(newDeviceName); } catch (IOException | TimeoutException | UserAlreadyExists e) { e.printStackTrace(); } - }).start(); + }); + thread.setName("dbus-link"); + thread.start(); return deviceLinkUri.toString(); } catch (TimeoutException | IOException e) { throw new SignalControl.Error.Failure(e.getClass().getSimpleName() + " " + e.getMessage());