|
@@ -259,13 +259,12 @@ public final class DocxProcessUtil {
|
|
htmlSettings.setWmlPackage(wordMLPackage);
|
|
htmlSettings.setWmlPackage(wordMLPackage);
|
|
String tmpHtmlPath = TEMP_FILE_IMP + UUID.randomUUID().toString() + ".html";
|
|
String tmpHtmlPath = TEMP_FILE_IMP + UUID.randomUUID().toString() + ".html";
|
|
File tmpHtml = new File(tmpHtmlPath);
|
|
File tmpHtml = new File(tmpHtmlPath);
|
|
- OutputStream os = new java.io.FileOutputStream(tmpHtml);
|
|
+ OutputStream os = new FileOutputStream(tmpHtml);
|
|
Docx4J.toHTML(htmlSettings, os, Docx4J.FLAG_EXPORT_PREFER_XSL);
|
|
Docx4J.toHTML(htmlSettings, os, Docx4J.FLAG_EXPORT_PREFER_XSL);
|
|
os.flush();
|
|
os.flush();
|
|
-
|
|
+ os.close();
|
|
|
|
|
|
String htmlStr = formatHtmlByPath(tmpHtmlPath);
|
|
String htmlStr = formatHtmlByPath(tmpHtmlPath);
|
|
-
|
|
|
|
|
|
|
|
FileUtils.deleteQuietly(tmpHtml);
|
|
FileUtils.deleteQuietly(tmpHtml);
|
|
|
|
|