Uploaded image for project: 'Code Tools'
  1. Code Tools
  2. CODETOOLS-7024690

Memory leak in test suite properties dialog

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • P3
    • jt4.4.1
    • jt4.4
    • tools
    • None
    • b06
    • x86
    • generic
    • Not verified

    Description

      Open any test suite in JavaTest, then View -> Properties. Close the dialog and the test suite.

      Still, the whole test suite is retained in the memory due to improper cleanup in the ToolDialog.
      Here's the proof (from JHat tool):

      --> sun.awt.windows.WDialogPeer@0x4a9e670 (157 bytes) (field target:)
      --> javax.swing.JDialog@0x4a9c6f0 (426 bytes) (field windowListener:)
      --> com.sun.javatest.tool.ToolDialog$2@0x4aabf38 (12 bytes) (field this$0:)
      --> com.sun.javatest.exec.PropertiesBrowser@0x4a4c9a0 (100 bytes) (field testSuite:)
      --> com.sun.tck.msa.javatest.MSATestSuite@0x152abda0 (115 bytes)

      So, the JDialog is not properly disposed and it keeps the reference to the test suite via its listener.
      Attached patch fixes the problem for me.

      Attachments

        Activity

          People

            bkurotsu Brian Kurotsuchi (Inactive)
            vsizikov Vladimir Sizikov
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: