hwloc in 20.04 leaks memory

Bug #1962215 reported by kraffenetti
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
hwloc (Ubuntu)
New
Undecided
Unassigned

Bug Description

This simple hwloc program leaks memory with the libhwloc-dev packages on 20.04. Building hwloc v2.1.0 from git source does not exhibit the same leak.

compute-240-10% cat /etc/issue
Ubuntu 20.04.3 LTS \n \l
compute-240-10% dpkg -l | grep hwloc-dev
ii libhwloc-dev:amd64 2.1.0+dfsg-4 amd64 Hierarchical view of the machine - static libs and headers
compute-240-10% gcc -fsanitize=leak hwloc-leak.c -lhwloc
compute-240-10% ./a.out

=================================================================
==2036999==ERROR: LeakSanitizer: detected memory leaks

Direct leak of 88 byte(s) in 1 object(s) allocated from:
    #0 0x7fbe675fa9c1 in __interceptor_malloc ../../../../src/libsanitizer/lsan/lsan_interceptors.cpp:54
    #1 0x7fbe671dda8c in lt__malloc (/lib/x86_64-linux-gnu/libltdl.so.7+0x2a8c)

SUMMARY: LeakSanitizer: 88 byte(s) leaked in 1 allocation(s).
compute-240-10% cat hwloc-leak.c
#include <assert.h>
#include "hwloc.h"

int main(void)
{
  hwloc_topology_t topology;
  int err;

  err = hwloc_topology_init(&topology);
  assert(!err);
  hwloc_topology_destroy(topology);
  return 0;
}

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.