GDIPlus functions cause a memory leak.

Viewing 7 posts - 1 through 7 (of 7 total)
  • Author
    Posts
  • #58311
    Support
    Keymaster

      Hello and thank you for researching.

      I will check and fix it.

      #58313
      HeDiBo
      Participant
        'Support' wrote:

        Hello and thank you for researching.

        I will check and fix it.

        I found that removing the memory leak from TsSplitView, removes the other ones too.

        This change did it:

        Code:
        destructor TsSplitView.Destroy;
        begin
        FBlurData.Free;
        FreeAndNil(BGBmp); (*** DB ***)
        FreeAndNil(BluredBmp); (*** DB ***)
        inherited;
        end;

        #58323
        Support
        Keymaster

          Hello and thank you for the information.

          I have checked GDI Plus functions, GdiplusStartup is called there in the acGDIBegin procedure.

          Memory leak will be removed very soon I think, some problems with reproduction of the problem exists.

          #58315
          HeDiBo
          Participant
            'Support' wrote:

            Hello and thank you for the information.

            I have checked GDI Plus functions, GdiplusStartup is called there in the acGDIBegin procedure.

            Memory leak will be removed very soon I think, some problems with reproduction of the problem exists.

            The problem is only in TsSplitView, as mentioned above. Freeing the bitmaps mentioned will solve the memory leak.

            #58316
            Support
            Keymaster

              Yes, this code should work, but it will be great if I can find a reason of this leak.

              #58317
              HeDiBo
              Participant
                'Support' wrote:

                Yes, this code should work, but it will be great if I can find a reason of this leak.

                In sPanel the allocation of BGBmp especially is a bit fishy. It is very hard to find why it is freed if the application is stopped when the bitmap is allocated.

                #58390
                HeDiBo
                Participant

                  Solved. a3.gif

                  (You didn't need to keep my initials in the bug fix, but I appreciate it.) rolleyes.gif

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