Aspose.Words.Document throwing a NullReferenceException with some files

An exception has been throwen while opening some word template files.
The bug occures on versions 22.2-22.5. before 22.2 it worked.
This bug causes a serious problems to our customers. Please give this a high priority.
A template file for example is attached.template-for-example.zip (89.8 KB)

At this line:

Aspose.Words.Document srcDoc = new Aspose.Words.Document(templateFileName);

I got this exception:

System.NullReferenceException
  HResult=0x80004003
  Message=Object reference not set to an instance of an object.
  Source=Aspose.Words
  StackTrace:
   at    . (Table )

@prioritydev Unfortunately, I cannot reproduce the problem on my side using the latest 22.5 version of Aspose.Words. I can successfully open and save the attached document on my side.
Could you please create a simple application that will allow us to reproduce the problem? We will check the issue and provide you more information. Also, please provide more information about the environment where the problem occurs.

Hi Alexey,
I’ve attached an example console-program, with two docx filesbug-demo-for-Aspose.Words.zip (204.0 KB)
. When you run it with “with-bug.docx” as an argument, it will crash as I described above. But, if you will downgrade Aspose to 22.1, it will do work.
The second file, “without-bug.docx” will be proccessed successfully anyways.

@prioritydev Thank you for additional information. I have managed to reproduce the problem with the newly attached document. For a sake of correction it has been logged as WORDSNET-23913. We will keep you informed and let you know once it is resolved.
Note, MS Word on my side also cannot open the problematic document.

Hi,
I saw the status of this issue was moved into close.
Does that mean this bug will be fixed in the next release?

@prioritydev Yes, the issue is already resolved in the current codebase. The fix will be included into the next 22.7 version of Aspose.Words. We are going to publish it in a week or so. We will be sure to notify you once it is available.

The issues you have found earlier (filed as WORDSNET-23913) have been fixed in this Aspose.Words for .NET 22.7 update also available on NuGet.