Fix: Incorrect order data was written out
This commit is contained in:
+1
-1
@@ -50,8 +50,8 @@ public class TcpTransport implements TransportLayer {
|
|||||||
int requestId = data.requestId();
|
int requestId = data.requestId();
|
||||||
byte[] rawPayload = data.payload().getBytes(StandardCharsets.UTF_8);
|
byte[] rawPayload = data.payload().getBytes(StandardCharsets.UTF_8);
|
||||||
|
|
||||||
out.writeInt(requestId);
|
|
||||||
out.writeInt(rawPayload.length);
|
out.writeInt(rawPayload.length);
|
||||||
|
out.writeInt(requestId);
|
||||||
out.write(rawPayload);
|
out.write(rawPayload);
|
||||||
out.flush();
|
out.flush();
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user