1
0
mirror of https://github.com/SquidDev-CC/CC-Tweaked synced 2025-10-20 16:37:39 +00:00

Fix several off-by-one issues in UploadFileMessage

We now fuzz UploadFileMessage, generating random files and checking they
round-trip correctly.

The joy of having a long-lasting refactor branch with an absolutely
massive diff, is that you end up spotting bugs, and then it's a massive
pain to merge the fix back into trunk!
This commit is contained in:
Jonathan Coates
2022-10-21 23:10:18 +01:00
parent b663028f42
commit 1e703f1b07
12 changed files with 572 additions and 20 deletions

View File

@@ -0,0 +1,25 @@
/*
* This file is part of ComputerCraft - http://www.computercraft.info
* Copyright Daniel Ratcliffe, 2011-2022. Do not distribute without permission.
* Send enquiries to dratcliffe@gmail.com
*/
package dan200.computercraft.support;
import net.minecraft.entity.player.PlayerEntity;
import net.minecraft.inventory.container.Container;
import javax.annotation.Nonnull;
public class FakeContainer extends Container
{
public FakeContainer()
{
super( null, 0 );
}
@Override
public boolean stillValid( @Nonnull PlayerEntity player )
{
return true;
}
}