From 7b0313f9b81b9cba347e0d59602266c71a15cb32 Mon Sep 17 00:00:00 2001 From: Jussi Koskela Date: Mon, 12 Mar 2018 09:35:47 +0200 Subject: [PATCH] Truncate file after writing DataContainer to it refs #7810 Change-Id: I5ab3f7b1e173b22f1183d4c1fbef1d5d260030e4 --- .../src/org/simantics/databoard/container/DataContainers.java | 1 + 1 file changed, 1 insertion(+) diff --git a/bundles/org.simantics.databoard/src/org/simantics/databoard/container/DataContainers.java b/bundles/org.simantics.databoard/src/org/simantics/databoard/container/DataContainers.java index 4a74e2e50..21e54d897 100644 --- a/bundles/org.simantics.databoard/src/org/simantics/databoard/container/DataContainers.java +++ b/bundles/org.simantics.databoard/src/org/simantics/databoard/container/DataContainers.java @@ -232,6 +232,7 @@ public class DataContainers { BinaryFile wf = new BinaryFile( output); try { writeFile(wf, container); + wf.setLength(wf.position()); } finally { wf.close(); } -- 2.47.1