qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Stefan Hajnoczi <stefanha@redhat.com>
To: "Andreas Färber" <afaerber@suse.de>
Cc: pbonzini@redhat.com, Cam Macdonell <cam@cs.ualberta.ca>,
	qemu-devel@nongnu.org, mst@redhat.com
Subject: Re: [Qemu-devel] [RFC] tests: Add ivshmem qtest
Date: Thu, 3 Apr 2014 10:46:24 +0200	[thread overview]
Message-ID: <20140403084624.GD27704@stefanha-thinkpad.redhat.com> (raw)
In-Reply-To: <1396450668-12145-1-git-send-email-afaerber@suse.de>

On Wed, Apr 02, 2014 at 04:57:48PM +0200, Andreas Färber wrote:
> +int main(int argc, char **argv)
> +{
> +    QTestState *s1, *s2;
> +    char *cmd;
> +    int ret;
> +
> +    g_test_init(&argc, &argv, NULL);
> +    qtest_add_func("/ivshmem/nop", nop);
> +
> +    cmd = g_strdup_printf("-device ivshmem,shm=%s,size=1M", "qtest");

This test leaks the "qtest" shm object that gets created by the first
QEMU process.  The name is constant so two instances of the test cannot
run in parallel on the same machine (the objects go in /dev/shm).

The name should be unique and we should clean up in both success and
failure (abort(3)) cases.

Stefan

  parent reply	other threads:[~2014-04-03  8:46 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-04-02 14:57 [Qemu-devel] [RFC] tests: Add ivshmem qtest Andreas Färber
2014-04-02 15:06 ` Michael S. Tsirkin
2014-04-02 15:07   ` Andreas Färber
2014-04-02 15:15     ` Michael S. Tsirkin
2014-04-02 15:15       ` Paolo Bonzini
2014-04-03 11:16         ` Michael S. Tsirkin
2014-04-03 11:23           ` Andreas Färber
2014-04-03 13:33             ` Michael S. Tsirkin
2014-04-03  8:46 ` Stefan Hajnoczi [this message]
2014-04-03 11:45   ` Andreas Färber
2014-04-03 12:58     ` Stefan Hajnoczi

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=20140403084624.GD27704@stefanha-thinkpad.redhat.com \
    --to=stefanha@redhat.com \
    --cc=afaerber@suse.de \
    --cc=cam@cs.ualberta.ca \
    --cc=mst@redhat.com \
    --cc=pbonzini@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).