Xcos: ZCOS should not store the time 63/17563/2
Clément DAVID [Wed, 9 Dec 2015 15:32:22 +0000 (16:32 +0100)]
Change-Id: I9da0a198a1924ce6f0d414b9500c3760958069d4

scilab/modules/xcos/src/java/org/scilab/modules/xcos/io/spec/ContentEntry.java
scilab/modules/xcos/src/java/org/scilab/modules/xcos/io/spec/DictionaryEntry.java
scilab/modules/xcos/src/java/org/scilab/modules/xcos/io/spec/XcosPackage.java

index 4c4301f..60a04fa 100644 (file)
@@ -20,17 +20,8 @@ import java.util.zip.ZipOutputStream;
 
 import javax.xml.stream.XMLOutputFactory;
 import javax.xml.stream.XMLStreamException;
-import javax.xml.stream.XMLStreamReader;
 import javax.xml.stream.XMLStreamWriter;
-import javax.xml.transform.Transformer;
-import javax.xml.transform.TransformerConfigurationException;
-import javax.xml.transform.TransformerException;
-import javax.xml.transform.TransformerFactory;
-import javax.xml.transform.sax.SAXResult;
 import javax.xml.transform.stream.StreamResult;
-import javax.xml.transform.stream.StreamSource;
-
-import org.scilab.modules.commons.xml.ScilabTransformerFactory;
 import org.scilab.modules.commons.xml.ScilabXMLOutputFactory;
 import org.scilab.modules.xcos.graph.XcosDiagram;
 import org.scilab.modules.xcos.io.sax.XcosSAXHandler;
@@ -89,6 +80,7 @@ public class ContentEntry implements Entry {
          * Append a ZipEntry
          */
         final ZipEntry entry = new ZipEntry(getFullPath());
+        entry.setTime(0l);
         stream.putNextEntry(entry);
 
         /*
index f0bab23..e014fa8 100644 (file)
@@ -70,6 +70,7 @@ public class DictionaryEntry implements Entry {
          * Append a ZipEntry
          */
         final ZipEntry entry = new ZipEntry(getFullPath());
+        entry.setTime(0l);
         stream.putNextEntry(entry);
 
         /*
index 0706798..68e140a 100644 (file)
@@ -287,6 +287,7 @@ public class XcosPackage {
         crc.update(MIME_BYTES);
         entry.setCrc(crc.getValue());
         entry.setMethod(ZipEntry.STORED);
+        entry.setTime(0l);
         zout.putNextEntry(entry);
         zout.write(MIME_BYTES);
 
@@ -305,6 +306,7 @@ public class XcosPackage {
          * Append the entry
          */
         final ZipEntry entry = new ZipEntry(META_INF_MANIFEST_XML);
+        entry.setTime(0l);
         zout.putNextEntry(entry);
 
         /*