mirror of
https://github.com/LeavesMC/Leaves.git
synced 2025-12-20 15:29:35 +00:00
Try to fix replay api crash (#713)
* Try to fix replay api crash * Revert unnecessary volatile
This commit is contained in:
@@ -235,7 +235,11 @@ public class Recorder extends Connection {
|
|||||||
|
|
||||||
private void savePacket(Packet<?> packet, final ConnectionProtocol protocol) {
|
private void savePacket(Packet<?> packet, final ConnectionProtocol protocol) {
|
||||||
final long timestamp = getCurrentTimeAndUpdate();
|
final long timestamp = getCurrentTimeAndUpdate();
|
||||||
replayFile.savePacket(timestamp, packet, protocol);
|
try {
|
||||||
|
replayFile.savePacket(timestamp, packet, protocol);
|
||||||
|
} catch (Exception e) {
|
||||||
|
LOGGER.severe("Error saving packet on thread " + Thread.currentThread() + ". Are you using some plugin that modify data asynchronously?", e);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public boolean isSaved() {
|
public boolean isSaved() {
|
||||||
|
|||||||
Reference in New Issue
Block a user