mirror of
https://github.com/Pumpkin-MC/Pumpkin.git
synced 2026-08-30 20:14:23 +00:00
fix: empty command kick (#1814)
* fix: piston not unextending * chore: make clippy happy * fix: empty command kick * chore: oops --------- Signed-off-by: Greened <108997309+GreenedDev@users.noreply.github.com>
This commit is contained in:
@@ -104,7 +104,7 @@ impl<R: Read> NetworkReadExt for R {
|
||||
fn read_boxed_slice(&mut self, length: usize) -> Result<Box<[u8]>, ReadingError> {
|
||||
// Increase this to at least 2MB to handle larger Bedrock batches
|
||||
const MAX_SLICE_LENGTH: usize = 2 * 1024 * 1024; // 2MB
|
||||
if !(1..=MAX_SLICE_LENGTH).contains(&length) {
|
||||
if !(0..=MAX_SLICE_LENGTH).contains(&length) {
|
||||
return Err(ReadingError::Message(format!(
|
||||
"read_boxed_slice: length {length} out of bounds"
|
||||
)));
|
||||
|
||||
Reference in New Issue
Block a user