From: Richard Henderson <richard.henderson@linaro.org>
To: "Thomas Huth" <thuth@redhat.com>,
"Philippe Mathieu-Daudé" <philmd@redhat.com>,
qemu-devel@nongnu.org, "Laurent Vivier" <lvivier@redhat.com>
Cc: Paolo Bonzini <pbonzini@redhat.com>
Subject: Re: [PATCH] tests/qtest/virtio-net-failover: Use g_random_int() instead of g_test_rand_int()
Date: Tue, 21 Dec 2021 11:32:50 -0800 [thread overview]
Message-ID: <fe3c4739-48f0-bb42-77a0-3677ccb22391@linaro.org> (raw)
In-Reply-To: <656b10c3-4edc-96bd-48b6-3302ddd7cb7c@redhat.com>
On 12/21/21 2:32 AM, Thomas Huth wrote:
> Using g_file_open_tmp is certainly better ... but the tests are currently written in a way
> where they require the file name of the temporary file - so switching to g_file_open_tmp()
> (which only provides a file handle) certainly would need some rewrite here...
Incorrect. g_file_open_tmp returns the open file handle, but also returns the filename in
*name_used.
I should think you can close the file handle straight away and use the filename.
r~
next prev parent reply other threads:[~2021-12-21 19:37 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-12-20 10:27 [PATCH] tests/qtest/virtio-net-failover: Use g_random_int() instead of g_test_rand_int() Thomas Huth
2021-12-20 11:54 ` Laurent Vivier
2021-12-20 13:16 ` Philippe Mathieu-Daudé
2021-12-20 19:26 ` Richard Henderson
2021-12-20 20:02 ` Philippe Mathieu-Daudé
2021-12-21 10:32 ` Thomas Huth
2021-12-21 19:32 ` Richard Henderson [this message]
2021-12-22 7:02 ` Thomas Huth
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=fe3c4739-48f0-bb42-77a0-3677ccb22391@linaro.org \
--to=richard.henderson@linaro.org \
--cc=lvivier@redhat.com \
--cc=pbonzini@redhat.com \
--cc=philmd@redhat.com \
--cc=qemu-devel@nongnu.org \
--cc=thuth@redhat.com \
/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).