From: "Daniel P. Berrange" <berrange@redhat.com>
To: Paolo Bonzini <pbonzini@redhat.com>
Cc: qemu-devel@nongnu.org, "Marc-André Lureau" <marcandre.lureau@redhat.com>
Subject: Re: [Qemu-devel] [PATCH v2 1/1] chardev: convert the socket server to QIONetListener
Date: Wed, 20 Dec 2017 16:25:20 +0000 [thread overview]
Message-ID: <20171220162520.GU21216@redhat.com> (raw)
In-Reply-To: <f2953a7c-a107-4b42-527e-05e708f1fffd@redhat.com>
On Wed, Dec 20, 2017 at 05:23:17PM +0100, Paolo Bonzini wrote:
> On 19/12/2017 09:48, Paolo Bonzini wrote:
> > On 18/12/2017 14:54, Daniel P. Berrange wrote:
> >> Instead of creating a QIOChannelSocket directly for the chardev
> >> server socket, use a QIONetListener. This provides the ability
> >> to listen on multiple sockets at the same time, so enables
> >> full support for IPv4/IPv6 dual stack.
> >>
> >> Signed-off-by: Daniel P. Berrange <berrange@redhat.com>
> >> ---
> >> chardev/char-socket.c | 72 +++++++++++++++++++++------------------------------
> >> 1 file changed, 29 insertions(+), 43 deletions(-)
> >
> > Queued, thanks.
>
> I think this has to be squashed in to avoid use-after-free issues left and right
> (visible with test-hmp):
>
> diff --git a/chardev/char-socket.c b/chardev/char-socket.c
> index 2d2252a..630a7f2 100644
> --- a/chardev/char-socket.c
> +++ b/chardev/char-socket.c
> @@ -930,6 +930,7 @@ static void qmp_chardev_open_socket(Chardev *chr,
>
> if (qio_net_listener_open_sync(s->listener, s->addr, errp) < 0) {
> object_unref(OBJECT(s->listener));
> + s->listener = NULL;
> goto error;
> }
Yes, that makes sense given the context, though I can't reproduce the test
failures myself yet. Any, please do squash it into the patch, as it makes
sense. Reviewed-by: Daniel P. Berrange <berrange@redhat.com>
Regards,
Daniel
--
|: https://berrange.com -o- https://www.flickr.com/photos/dberrange :|
|: https://libvirt.org -o- https://fstop138.berrange.com :|
|: https://entangle-photo.org -o- https://www.instagram.com/dberrange :|
prev parent reply other threads:[~2017-12-20 16:25 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-12-18 13:54 [Qemu-devel] [PATCH v2 0/1] Enable full IPv4/IPv6 dual stack support in chardevs Daniel P. Berrange
2017-12-18 13:54 ` [Qemu-devel] [PATCH v2 1/1] chardev: convert the socket server to QIONetListener Daniel P. Berrange
2017-12-19 8:48 ` Paolo Bonzini
2017-12-20 16:23 ` Paolo Bonzini
2017-12-20 16:25 ` Daniel P. Berrange [this message]
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=20171220162520.GU21216@redhat.com \
--to=berrange@redhat.com \
--cc=marcandre.lureau@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).