diff options
author | Magdalena Grodzińska <mag.grodzinska@gmail.com> | 2020-01-06 16:32:45 +0100 |
---|---|---|
committer | Magdalena Grodzińska <mag.grodzinska@gmail.com> | 2020-01-06 16:32:45 +0100 |
commit | 6027e8ffcc91495dc1cfe76da925e846f57646e7 (patch) | |
tree | 2db194e3123a3dc9c570c1c8e8220902d51da853 /src/main/java/pl/edu/mimuw/cloudatlas/agent | |
parent | f8e0f371515a825ead0bf385105b461223c55e71 (diff) |
Fix passing messages in server
Diffstat (limited to 'src/main/java/pl/edu/mimuw/cloudatlas/agent')
-rw-r--r-- | src/main/java/pl/edu/mimuw/cloudatlas/agent/modules/UDUPServer.java | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/main/java/pl/edu/mimuw/cloudatlas/agent/modules/UDUPServer.java b/src/main/java/pl/edu/mimuw/cloudatlas/agent/modules/UDUPServer.java index 9a64bbd..6807a86 100644 --- a/src/main/java/pl/edu/mimuw/cloudatlas/agent/modules/UDUPServer.java +++ b/src/main/java/pl/edu/mimuw/cloudatlas/agent/modules/UDUPServer.java @@ -37,7 +37,9 @@ public class UDUPServer { if (packet.getLength() == this.bufSize) { this.addPartialMessageAndCheckSerialization(packet.getAddress(), packet.getData()); } else { - if (msg.getDestinationModule() != ModuleType.UDP) { + if (msg.getContent().getDestinationModule() == ModuleType.TEST) { + System.out.println("UDP server: test message received"); + } else if (msg.getContent().getDestinationModule() != ModuleType.UDP) { this.udp.sendMessage(msg.getContent()); } } |