fails to read a STEP file (OCCT 7.7.0)

I attempted to read a STEP file using STEPCAFControl_Reader,

but the program crashes when I call the Transfer.

My current code is as follows:

Handle(XCAFApp_Application) hApp = XCAFApp_Application::GetApplication(); 
Handle(TDocStd_Document) hDoc; 
hApp->NewDocument(TCollection_ExtendedString("MDTV-CAF"), hDoc);

STEPCAFControl_Reader aReader; 
aReader.SetColorMode(true); 
aReader.SetNameMode(true); 
aReader.SetLayerMode(true); 
aReader.SetSHUOMode(true); 

aReader.ReadFile("my_step_file_path"); 
aReader.Transfer(hDoc); 

This issue only occurs with this specific STEP file (which I have attached below), the crashes are almost never encountered with other STEP files.

I can import this STEP file without any crashes using FreeCAD 2.0.

Could it be that version 7.7 has trouble parsing this STEP file?

Attachments: 
Dmitrii Pasukhin's picture

Ticket created: 0033680: Data Exchange - Crash while while reading a STEP file - MantisBT (opencascade.org)

Waiting for analyzing.

Best regards, Dmitrii.

Mason Chen's picture

Thanks for your response.
Can this STEP file be parsed without errors on a higher version?

Dmitrii Pasukhin's picture

Hello, 7.8 release fixed issue.

Best regards, Dmitrii.