Image extraction issue 8

Dear team,

We are extracting images from docx using aspose java, but below case we are getting one red line in extracted image please find source code and Input & output files

Source code :

Document tableDoc = docSetup(interimdoc, table);
NodeImporter importers = new NodeImporter(interimdoc, tableDoc, ImportFormatMode.KEEP_SOURCE_FORMATTING);
tableDoc.getFirstSection().getBody().appendChild(importers.importNode(table, true));
tableDoc.save(AIE.pdfFolder + saveAS);
if ((table.getPreviousSibling() != null && !AIE.removeEquationShapes(tableDoc)
		&& table.getPreviousSibling().getNodeType() == NodeType.PARAGRAPH)
		|| ((Paragraph)table.getNextSibling()).getParentSection().getBody().indexOf(table) == 0)
{

Input : New Microsoft Word Document.docx (266.4 KB)

output : Fig0014.pdf (137.2 KB)
Fig0015.pdf (146.1 KB)

@e503824 Unfortunately, I cannot reproduce the problem on my side. Here is the code I used for testing:

Document doc = new Document("C:\\Temp\\in.docx");

Iterable<Table> tables = doc.getChildNodes(NodeType.TABLE, true);

int i = 0;
for (Table t : tables)
{
    Document dstDoc = (Document)doc.deepClone(false);
    Node dstSect = dstDoc.importNode(t.getAncestor(NodeType.SECTION), false, ImportFormatMode.USE_DESTINATION_STYLES);
    dstDoc.appendChild(dstSect);
    dstDoc.ensureMinimum();

    Node dstNode = dstDoc.importNode(t, true, ImportFormatMode.USE_DESTINATION_STYLES);
    dstDoc.getFirstSection().getBody().appendChild(dstNode);

    dstDoc.save("C:\\Temp\\out_" + i + ".pdf");
    i++;
}

Here are the output documents generated by this code: out_0.pdf (137.3 KB) out_1.pdf (146.2 KB)