aboutsummaryrefslogtreecommitdiffstats
path: root/poi-scratchpad/src/test/java/org/apache/poi/hslf/HSLFTestDataSamples.java
diff options
context:
space:
mode:
Diffstat (limited to 'poi-scratchpad/src/test/java/org/apache/poi/hslf/HSLFTestDataSamples.java')
-rw-r--r--poi-scratchpad/src/test/java/org/apache/poi/hslf/HSLFTestDataSamples.java4
1 files changed, 2 insertions, 2 deletions
diff --git a/poi-scratchpad/src/test/java/org/apache/poi/hslf/HSLFTestDataSamples.java b/poi-scratchpad/src/test/java/org/apache/poi/hslf/HSLFTestDataSamples.java
index 881d543b0d..39d5a32482 100644
--- a/poi-scratchpad/src/test/java/org/apache/poi/hslf/HSLFTestDataSamples.java
+++ b/poi-scratchpad/src/test/java/org/apache/poi/hslf/HSLFTestDataSamples.java
@@ -54,7 +54,7 @@ public class HSLFTestDataSamples {
* Useful for verifying that the serialisation round trip
*/
public static HSLFSlideShowImpl writeOutAndReadBack(HSLFSlideShowImpl original) {
- try (UnsynchronizedByteArrayOutputStream baos = new UnsynchronizedByteArrayOutputStream()) {
+ try (UnsynchronizedByteArrayOutputStream baos = UnsynchronizedByteArrayOutputStream.builder().get()) {
original.write(baos);
try (InputStream is = baos.toInputStream()) {
return new HSLFSlideShowImpl(is);
@@ -70,7 +70,7 @@ public class HSLFTestDataSamples {
* Useful for verifying that the serialisation round trip
*/
public static HSLFSlideShow writeOutAndReadBack(HSLFSlideShow original) {
- try (UnsynchronizedByteArrayOutputStream baos = new UnsynchronizedByteArrayOutputStream(4096)) {
+ try (UnsynchronizedByteArrayOutputStream baos = UnsynchronizedByteArrayOutputStream.builder().setBufferSize(4096).get()) {
original.write(baos);
return new HSLFSlideShow(baos.toInputStream());
} catch (IOException e) {