From 603c6af6455c6ea2b2edb6912cfbdf069160b833 Mon Sep 17 00:00:00 2001 From: raoulvdberge Date: Tue, 20 Dec 2022 14:44:42 +0100 Subject: [PATCH 1/2] Bump to v1.11.4. --- CHANGELOG.md | 2 ++ build.gradle | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 165c8bd8f..2c994759b 100755 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -7,6 +7,8 @@ to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). ## [Unreleased] +## [v1.11.3] - 2022-12-20 + ### Fixed - Fixed external storage cache being de-synced from the network cache. diff --git a/build.gradle b/build.gradle index 46e205d3b..5874083b8 100755 --- a/build.gradle +++ b/build.gradle @@ -33,7 +33,7 @@ apply plugin: 'maven-publish' group = 'com.refinedmods' archivesBaseName = 'refinedstorage' -version = '1.11.3' +version = '1.11.4' if (System.getenv('GITHUB_SHA') != null) { version += '+' + System.getenv('GITHUB_SHA').substring(0, 7) From a47dc166c10852f69a4e1994868e136902b7dd01 Mon Sep 17 00:00:00 2001 From: raoulvdberge Date: Tue, 20 Dec 2022 16:23:52 +0100 Subject: [PATCH 2/2] Fixed duplication bug in the Interface. Fixes #3414 This was a problem with returning the remainder if there are valid storages, but they are all in extract-only (the #insert call never propagates to IStorage in that case). If stack.size differs from size, the stack with its wrong size is returned literally as remainder in that case, which breaks an assumption in the interface. --- CHANGELOG.md | 4 ++++ .../refinedmods/refinedstorage/apiimpl/network/Network.java | 4 ++-- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 2c994759b..dd861a945 100755 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -7,6 +7,10 @@ to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). ## [Unreleased] +### Fixed + +- Fixed duplication bug in the Interface. + ## [v1.11.3] - 2022-12-20 ### Fixed diff --git a/src/main/java/com/refinedmods/refinedstorage/apiimpl/network/Network.java b/src/main/java/com/refinedmods/refinedstorage/apiimpl/network/Network.java index 7911ee248..a24afc297 100644 --- a/src/main/java/com/refinedmods/refinedstorage/apiimpl/network/Network.java +++ b/src/main/java/com/refinedmods/refinedstorage/apiimpl/network/Network.java @@ -273,7 +273,7 @@ public class Network implements INetwork, IRedstoneConfigurable { return ItemHandlerHelper.copyStackWithSize(stack, size); } - ItemStack remainder = stack; + ItemStack remainder = ItemHandlerHelper.copyStackWithSize(stack, size); int inserted = 0; int insertedExternally = 0; @@ -380,7 +380,7 @@ public class Network implements INetwork, IRedstoneConfigurable { return StackUtils.copy(stack, size); } - FluidStack remainder = stack; + FluidStack remainder = StackUtils.copy(stack, size); int inserted = 0; int insertedExternally = 0;