On Wed, Apr 26, 2017 at 04:04:14PM +0800, Mao Zhongyi wrote: > v2: > * PATCH 02 reworking of patch 2 following Markus's suggestion that convert > error_report() > in the function called by net_socket_*_init() to Error. Also add many error > handling > information. > * PATCH 03 net_socket_mcast_create(), net_socket_fd_init_dgram() and > net_socket_fd_init() > use the function such as fprintf, perror to report an error message. > Convert it to Error. > * PATCH 04 parse_host_port() may fail without reporting an error. Now, fix it > to set an > error when it fails.
FYI, I discovered that previous change commit 883e4f7624e10b98d16d9adaffb8b1795664d899 Author: Marc-André Lureau <marcandre.lur...@redhat.com> Date: Sat Jun 18 13:24:02 2016 +0530 Change net/socket.c to use socket_*() functions has seriously broken the current code because net_socket_fd_init() was not called from the right place. Fixing the current code is somewhat painful, so I've sent a revert of that broken patch. To demo the problem first run: $ ./x86_64-softmmu/qemu-system-x86_64 \ -device e1000,id=e0,netdev=user.0,mac=DE:AD:BE:EF:AF:04 \ -netdev socket,id=user.0,listen=:1234 and then run: $ ./x86_64-softmmu/qemu-system-x86_64 \ -device e1000,id=e0,netdev=hn0,mac=DE:AD:BE:EF:AF:05 \ -netdev socket,id=hn0,connect=localhost:1234 currently the second command fails with qemu-system-x86_64: -device e1000,id=e0,netdev=hn0,mac=DE:AD:BE:EF:AF:05: Property 'e1000.netdev' can't find value 'hn0' and my revert fixes that. Just something for you to test with your new patch series... 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 :|