10.16 Access Violation

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #36676
    asymtek
    Participant

    This is probably happening on 10.17. We just have not updated yet.

    We are getting an access violation.

    What we are doing is creating an object from a TPanel class that contains a stringgrid and placing that object on a panel in a form. When we close the form we are freeing the object. This is where we are getting the AV. If we bypass freeing the object no AV. Also there is no AV when the skins manager is not active.

    The AV is occurring in the acSBUtils RestoreStdParams on the first line “inherited”.

    We are using “ReportMemoryLeaksOnShutdown := True;” and do not report a memory leak when the object is not freed. However, I am not sure if this is accurate. Is it wrong to free the object when it is control? Should we let the form free this object? Very puzzling.

    I have included a sample project to demonstrate what we have found.

    #53995
    Support
    Keymaster

    Thank you for the demo. I think, “MyPanel.Free” is not required because MyPanel is freeing twice in this case.

    #54013
    asymtek
    Participant

    Thanks. That is what I thought.

Viewing 3 posts - 1 through 3 (of 3 total)
  • You must be logged in to reply to this topic.