Adium

Ticket #8892 (closed defect: fixed)

Opened 4 months ago

Last modified 3 months ago

Leak: Applescript in Status-Message

Reported by: TFS Assigned to: evands
Priority: normal Milestone: Adium X 1.2.2
Component: Scripting Version: 1.2
Severity: normal Keywords: AppleScript Status Message
Cc: evands, applmak Patch: None
Pending: 0

Description

General Info:
When using a Status-Message that contains AppleScript, Adium leaks vast amounts of Memory on my System (~1 - 1.5 MB/min).

System Information:
OS: Leopard
Adium: 1.2
Accounts: 3xICQ, 1xAIM, 1xMSN, 1xYahoo, 1xGTalk
Locale: German

Steps to reproduce
1. Install the attached Script (Other AppleScripts should also "work")
2. Go Away and set the Status Message to /intaway
3. Wait for Adium to gobble up memory ;)

Additional Info:
I can't say for sure, when the Problem appeared for the first time. I only noticed, that my Mac wouldn't wake up from "display sleep" sporadically (requiring a restart). I couldn't even ssh to it, making it hard to pin down the malfunction. So I let TOP run in the background. Today the machine froze again. I looked at the TOP-Output and saw, that Adium took my Memory away ;) . I started noticing the behaviour a few weeks back - I think it was even before the 1.2 Beta's, but I'm not sure.

Attached Files:
Leaks.zip: Leaks Output after 5/10/15/85 Minutes of Adium running with AS-Status.
top.txt.zip: Top Output over several hours. Status-MSG was set at ~8:00
AScript.zip: AppleScript beeing used in my Tests (although any script should work)

Attachments

AScript.zip (4.3 kB) - added by TFS on 01/11/2008 08:17:49 AM.
AppleScript beeing used in my Tests. Other's should produce the same behaviour.
top.txt.zip (408.3 kB) - added by TFS on 01/11/2008 08:20:05 AM.
Top Output sorted by RSIZE, Sample-Rate: 5 secs. Status set at ~8:00. The last entry indicates the freezing of my Mac.
Leaks.zip (17.0 kB) - added by TFS on 01/11/2008 08:21:18 AM.
lks_xxxx: Leaks Output at xxxx local time.

Change History

01/11/2008 08:17:49 AM changed by TFS

  • attachment AScript.zip added.

AppleScript beeing used in my Tests. Other's should produce the same behaviour.

01/11/2008 08:20:05 AM changed by TFS

  • attachment top.txt.zip added.

Top Output sorted by RSIZE, Sample-Rate: 5 secs. Status set at ~8:00. The last entry indicates the freezing of my Mac.

01/11/2008 08:21:18 AM changed by TFS

  • attachment Leaks.zip added.

lks_xxxx: Leaks Output at xxxx local time.

01/11/2008 03:06:21 PM changed by djmori

  • milestone set to Adium X 1.2.1.

01/11/2008 11:22:32 PM changed by jas8522

  • cc set to evands, applmak.

01/14/2008 06:01:49 PM changed by evands

  • milestone changed from Adium X 1.2.1 to Adium X 1.2.2.

01/30/2008 02:44:45 PM changed by evands

The leaks output demonstrates that it's not a true leak, since the number of leaks doesn't (hardly) increases with time. That doesn't, of course, invalidate the memory issue - it's just that something is being kept around in a way that doesn't look to the system like a leak.

01/30/2008 03:03:34 PM changed by evands

  • owner changed from nobody to evands.
  • status changed from new to assigned.

01/30/2008 03:08:12 PM changed by evands

  • status changed from assigned to closed.
  • resolution set to fixed.

(In [22526]) When we receive a distributed notification, any objects added to the autorelease pool won't be released until the next time the program is sent an NSEvent, it appears. We therefore should use a manual autorelease pool around the observer methods to prevent build-up of any autoreleased memory. This fixes a problem in which memory usage would build up over time when an autoupdating status message was in use and Adium was left alone for a long period of time. Fixes #8892

01/30/2008 03:08:48 PM changed by evands

(In [22527]) Merged [22526]: When we receive a distributed notification, any objects added to the autorelease pool won't be released until the next time the program is sent an NSEvent, it appears. We therefore should use a manual autorelease pool around the observer methods to prevent build-up of any autoreleased memory. This fixes a problem in which memory usage would build up over time when an autoupdating status message was in use and Adium was left alone for a long period of time. Fixes #8892