← Back to team overview

group.of.nepali.translators team mailing list archive

[Bug 1631050] Re: cache'd pid recycling adds cached info to hash again causing double free on exit cleanup

 

This bug was fixed in the package cpustat - 0.01.25-1ubuntu0

---------------
cpustat (0.01.25-1ubuntu0) xenial; urgency=medium

  * Only add pid info to hash table if it is new (LP: #1631050)
    - fixes double free error on exit

 -- Colin King <colin.king@xxxxxxxxxxxxx>  Thu, 6 Oct 2016 17:17:18
+0100

** Changed in: cpustat (Ubuntu Xenial)
       Status: Fix Committed => Fix Released

-- 
You received this bug notification because you are a member of नेपाली
भाषा समायोजकहरुको समूह, which is subscribed to Xenial.
Matching subscriptions: Ubuntu 16.04 Bugs
https://bugs.launchpad.net/bugs/1631050

Title:
  cache'd pid recycling adds cached info to hash again causing double
  free on exit cleanup

Status in cpustat package in Ubuntu:
  Fix Released
Status in cpustat source package in Xenial:
  Fix Released

Bug description:
  [XENIAL SRU]

  [Impact]
  Cached pid info is added to the hash table even when it's a re-used pid info causing a double free on exit cleanup.  Only add pid info to hash table if it is newly allocated.

  [Test Case]
  Run cpustat for a long duration as follows:

  cpustat 1 -T -g

  ..and work through a lot of processes IDs until we re-use a PID, e.g.:

  stress-ng --fork 0 &

  and stop cpustat with SIGINT, one hits a double free as it exits

  [Regression Potential]

  Minimal, the fix stops an item being added to a cache'd hash list more
  than once, and that is a minimal impact on the main cpustat
  functionality.

  [Fix]
  Upstream commit http://kernel.ubuntu.com/git/cking/cpustat.git/commit/?id=dc7d2fe45560c414645bc286a7cd63f13b69dc6c

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/cpustat/+bug/1631050/+subscriptions