qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH V2] test-filter-mirror: pass UNIX domain socket


From: Daniel P . Berrangé
Subject: Re: [Qemu-devel] [PATCH V2] test-filter-mirror: pass UNIX domain socket through fd
Date: Wed, 30 Jan 2019 10:00:34 +0000
User-agent: Mutt/1.10.1 (2018-07-13)

On Wed, Jan 30, 2019 at 11:14:27AM +0800, Jason Wang wrote:
> The tests tries to let qemu server mode to process the connection
> which turns out to be racy after commit 8258292e18c3 ("monitor: Remove
> "x-oob", offer capability "oob" unconditionally"). This is because the
> filter may try to mirror the packets before UNIX socket object is
> ready (connected was set to true) from the view of qemu. In this case
> the packet will be dropped silently.
> 
> Fixing this by passing pre-connected socket created by socketpair() to
> qemu through fd.
> 
> Cc: Peter Maydell <address@hidden>
> Cc: Li Zhijian <address@hidden>
> Cc: Peter Xu <address@hidden>
> Cc: Dr. David Alan Gilbert <address@hidden>
> Cc: Zhang Chen <address@hidden>
> Cc: Markus Armbruster <address@hidden>
> Cc: Daniel P. Berrange <address@hidden>
> Signed-off-by: Jason Wang <address@hidden>
> ---
> Changes from v1:
> - close the socket pairs in the end of test
> ---
>  tests/test-filter-mirror.c | 22 ++++++++++------------
>  1 file changed, 10 insertions(+), 12 deletions(-)

Reviewed-by: Daniel P. Berrangé <address@hidden>


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 :|



reply via email to

[Prev in Thread] Current Thread [Next in Thread]