qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Peter Maydell <peter.maydell@linaro.org>
To: "Daniel P. Berrangé" <berrange@redhat.com>
Cc: qemu-devel@nongnu.org, Kevin Wolf <kwolf@redhat.com>,
	qemu-block@nongnu.org, Hanna Reitz <hreitz@redhat.com>,
	Michael Tokarev <mjt@tls.msk.ru>
Subject: Re: [PATCH] iotests: fix leak of tmpdir in dry-run mode
Date: Mon, 5 Feb 2024 15:45:28 +0000	[thread overview]
Message-ID: <CAFEAcA94RfwQKLec7gWZMwz8fyDn=W+Uwn+owi6MY-rOF7Rk4A@mail.gmail.com> (raw)
In-Reply-To: <20240205154019.1841037-1-berrange@redhat.com>

On Mon, 5 Feb 2024 at 15:41, Daniel P. Berrangé <berrange@redhat.com> wrote:
>
> Creating an instance of the 'TestEnv' class will create a temporary
> directory. This dir is only deleted, however, in the __exit__ handler
> invoked by a context manager.
>
> In dry-run mode, we don't use the TestEnv via a context manager, so
> were leaking the temporary directory. Since meson invokes 'check'
> 5 times on each configure run, developers /tmp was filling up with
> empty temporary directories.
>
> Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>

Could we also arrange for the temp directory to be created
with a name that makes it easy to identify what has created it?
Very generic names like "/tmp/tmpNNNNNNNN" are very hard to
pin down to the code that created them.

thanks
-- PMM


  reply	other threads:[~2024-02-05 15:46 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-02-05 15:40 [PATCH] iotests: fix leak of tmpdir in dry-run mode Daniel P. Berrangé
2024-02-05 15:45 ` Peter Maydell [this message]
2024-02-05 15:52 ` Michael Tokarev
2024-02-07 13:59 ` Kevin Wolf

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='CAFEAcA94RfwQKLec7gWZMwz8fyDn=W+Uwn+owi6MY-rOF7Rk4A@mail.gmail.com' \
    --to=peter.maydell@linaro.org \
    --cc=berrange@redhat.com \
    --cc=hreitz@redhat.com \
    --cc=kwolf@redhat.com \
    --cc=mjt@tls.msk.ru \
    --cc=qemu-block@nongnu.org \
    --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).