Bug 17893 - file descriptor leak when processing /etc/ConsoleKit/run-session.d
Summary: file descriptor leak when processing /etc/ConsoleKit/run-session.d
Status: RESOLVED FIXED
Alias: None
Product: ConsoleKit
Classification: Unclassified
Component: Daemon (show other bugs)
Version: unspecified
Hardware: All All
: medium normal
Assignee: william.jon.mccann
QA Contact:
URL: https://launchpad.net/ubuntu/+source/...
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2008-10-03 12:43 UTC by Steve Langasek
Modified: 2009-02-11 15:38 UTC (History)
1 user (show)

See Also:
i915 platform:
i915 features:


Attachments
patch to fix fd leak (373 bytes, patch)
2008-10-03 12:43 UTC, Steve Langasek
Details | Splinter Review

Description Steve Langasek 2008-10-03 12:43:01 UTC
Created attachment 19357 [details] [review]
patch to fix fd leak

Chris Jones observed that console-kit-daemon had open a large number of redundant file descriptors, pointing to /etc/ConsoleKit/run-session.d and 
/usr/lib/ConsoleKit/run-session.d.  It turns out that ck_run_programs() doesn't close the directory handles after iterating, resulting in a fd leak and a small memory leak.

The attached patch corrects this.
Comment 1 william.jon.mccann 2009-02-11 15:38:05 UTC
Sorry for the long delay.  Thanks for the patch!  I've committed it to master.


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.