mirror of
https://github.com/AsamK/signal-cli
synced 2025-08-29 18:40:39 +00:00
Synchronize plain text output of incoming messages
This commit is contained in:
parent
54d8ee2a40
commit
25314b1d17
1 changed files with 6 additions and 0 deletions
|
@ -25,6 +25,12 @@ public class ReceiveMessageHandler implements Manager.ReceiveMessageHandler {
|
|||
|
||||
@Override
|
||||
public void handleMessage(MessageEnvelope envelope, Throwable exception) {
|
||||
synchronized (writer) {
|
||||
handleMessageInternal(envelope, exception);
|
||||
}
|
||||
}
|
||||
|
||||
private void handleMessageInternal(MessageEnvelope envelope, Throwable exception) {
|
||||
var source = envelope.sourceAddress();
|
||||
writer.println("Envelope from: {} (device: {})",
|
||||
source.map(this::formatContact).orElse("unknown source"),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue