qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Igor Mammedov <imammedo@redhat.com>
To: qemu-devel@nongnu.org
Cc: mst@redhat.com
Subject: [Qemu-devel] possible leak in bios-tables-test.c
Date: Fri, 21 Dec 2018 18:23:51 +0100	[thread overview]
Message-ID: <20181221182351.7edab300@redhat.com> (raw)

When running test under valgrind it spits out a bunch of still reachable
allocations. most of them are glib g_test related but there is one that
belong to the test itself. I've found why it happens so reporting in hope
that someone else would be able to track it down.

reproducer:

make && make tests/bios-tables-test && QTEST_QEMU_BINARY=./x86_64-softmmu/qemu-system-x86_64 \
valgrind --tool=memcheck --leak-check=full --show-leak-kinds=all tests/bios-tables-test

==52347== 5 bytes in 1 blocks are still reachable in loss record 4 of 27
==52347==    at 0x4C29BC3: malloc (vg_replace_malloc.c:299)
==52347==    by 0x529F68D: g_malloc (in /usr/lib64/libglib-2.0.so.0.5600.1)
==52347==    by 0x52B869E: g_strdup (in /usr/lib64/libglib-2.0.so.0.5600.1)
==52347==    by 0x52CD151: g_get_tmp_dir (in /usr/lib64/libglib-2.0.so.0.5600.1)
==52347==    by 0x528664D: ??? (in /usr/lib64/libglib-2.0.so.0.5600.1)
==52347==    by 0x528733E: g_file_open_tmp (in /usr/lib64/libglib-2.0.so.0.5600.1)
==52347==    by 0x112484: dump_aml_files (bios-tables-test.c:272)
==52347==    by 0x112E68: test_acpi_asl (bios-tables-test.c:432)
==52347==    by 0x113BE3: test_acpi_one (bios-tables-test.c:649)
==52347==    by 0x113CB1: test_acpi_piix4_tcg (bios-tables-test.c:676)
==52347==    by 0x52C0290: ??? (in /usr/lib64/libglib-2.0.so.0.5600.1)
==52347==    by 0x52C014A: ??? (in /usr/lib64/libglib-2.0.so.0.5600.1)

                 reply	other threads:[~2018-12-21 17:24 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20181221182351.7edab300@redhat.com \
    --to=imammedo@redhat.com \
    --cc=mst@redhat.com \
    --cc=qemu-devel@nongnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).