Uploaded image for project: 'Apache Flex'
  1. Apache Flex
  2. FLEX-33403

Memory leak in PollingChannel.as

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Open
    • Minor
    • Resolution: Unresolved
    • Apache Flex 4.8 (parity release)
    • None
    • RPC: General
    • None

    Description

      In the development branch (though I believe this is an issue in most of all versions), PollingChannel.as:778, the code adds an event listener that is never released.

      This results in a leak of PollCommandMessageResponder objects and associated memory.

      Suggest that line 778 in the constructor for the private class PollCommandMessageResponder:

      channel.addEventListener(PropertyChangeEvent.PROPERTY_CHANGE, channelPropertyChangeHandler);

      be changed to:
      channel.addEventListener(PropertyChangeEvent.PROPERTY_CHANGE, channelPropertyChangeHandler, false, 0, true);

      To make the event listener use weak references, or refactor PollingChannel.as to remove the event listener before disposing of a PollCommandMessageResponder.

      Attachments

        Activity

          People

            Unassigned Unassigned
            jvanderberg Josh Vanderberg
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated: