[ORD CE 10.10 Release 2] Crash - Polyface inside a cell, no crash in Release 1

I have created a small reproducible sample, please find attached.
We were ready to release our next version of software and one of the developers updated to Release 2 and found this issue, it does not appear in Release 1.

It appears to be when a polyfacemesh is put into a cell. Drawing the mesh outside of a cell works fine. We can also draw other geometry within a cell and that works fine. It appears to be the combination of a polyfacemesh within a cell.

Building the example:
I have included the built dlls if you wanted to run them directly, or to build them yourself make sure the configuration is set to "Debug - Connect" and Platform "x64".

Reproducible steps:
1. Load the TestProject dll into OpenRoads Designer 2021 Release 2 (my specific version is 10.10.20.78).
2. Key-in "DrawWithNoCells". This will draw the meshes outside of a cell, which works fine. Zooming to extents will show the mesh.
3.Delete the drawn meshes from the model
4. Key-in "DrawCell1". This will draw a polyfacemesh in a cell.
5. At this point, interacting with the drawn cell (selecting, moving) will likely cause the "Access Violation Exception"
6. If it does not, Key-in "DrawCell2"

I have also included a screen recording of the issue. https://autode.sk/3Kc9jaz

5315.Microstation.Release2Crash.Sample.zip

Parents
  • Hi Joe,

    We detected that the AppendToCellOfCurrentElement() method, used in your code, has a potential to crash.

    I see your project has a native component (LowLevel.dll). As a workaround, try to use unmanaged code to add the PolyfaceMesh to the cell.

    I hope it helps.

  • Hi Henrique. I work at the same company as Joe, thanks for your response and help so far. Joe's sample is a heavily simplified version of the workflow within our product. We tried your suggestion of replacing the AppendToCellOfCurrentElement with the unmanaged equivalent but unfortunately it did not resolve it for us.

    The exception that we're seeing is an AccessViolationException, due to the nature of this it is very random and difficult to narrow it down any further and is causing us a lot of lost time and frustration.

    We are using a heavy mixture of the .NET and MDL APIs. When you say that you found an issue that may cause a crash, is it possible this issue may affect any of the other .NET methods? I must stress that we are not experiencing any issues in OpenRoads 2021 Release 1, this is only related to Release 2.

    Thanks again, I hope you're able to assist.

Reply
  • Hi Henrique. I work at the same company as Joe, thanks for your response and help so far. Joe's sample is a heavily simplified version of the workflow within our product. We tried your suggestion of replacing the AppendToCellOfCurrentElement with the unmanaged equivalent but unfortunately it did not resolve it for us.

    The exception that we're seeing is an AccessViolationException, due to the nature of this it is very random and difficult to narrow it down any further and is causing us a lot of lost time and frustration.

    We are using a heavy mixture of the .NET and MDL APIs. When you say that you found an issue that may cause a crash, is it possible this issue may affect any of the other .NET methods? I must stress that we are not experiencing any issues in OpenRoads 2021 Release 1, this is only related to Release 2.

    Thanks again, I hope you're able to assist.

Children