summary refs log tree commit diff stats
path: root/results/classifier/zero-shot/105/socket/1744009
blob: 9e306555497ae059b8843519bf0bbc6f3396b5a9 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
socket: 0.942
device: 0.941
network: 0.827
graphic: 0.823
semantic: 0.754
instruction: 0.697
mistranslation: 0.685
vnc: 0.661
other: 0.629
boot: 0.338
assembly: 0.293
KVM: 0.217

qemu for windows fails to use multicast socket as netdev

My host OS is Windows 7 x64 SP1. I installed qemu for windows from https://qemu.weilnetz.de/w64/.The version is 2.10.1, qemu-w64-setup-20171006.exe. I run qemu with the following command:

qemu-system-x86_64.exe -net nic -net socket,mcast=234.5.5.5:6000 disk1.qcow2

It stopped with error:
bind: Unknown error
qemu-system-x86_64.exe: -net socket,mcast=234.5.5.5:6000: Device 'socket' could not be initialized

Using the -netdev option has the same problem:
qemu-system-x86_64.exe -netdev socket,id=hostnet0,mcast=234.5.5.5:6000 -device e1000,netdev=hostnet0 disk1.qcow2

I tried many versions from https://qemu.weilnetz.de/w64/, but none of them could work.

When I checked the source code, I think the problem is that on Microsoft Windows bind() can not use a multicast address.

MSDN bind() reference
https://msdn.microsoft.com/en-us/library/windows/desktop/ms737550(v=vs.85).aspx
seems to have indicated the point.

I changed the net_socket_mcast_create() in net/socket.c, make it bind to htonl(INADDR_ANY). After compiling, it seems to work correctly.

Have you ever tried to suggest your change as a patch to the qemu-devel mailing list? See:
https://wiki.qemu.org/Contribute/SubmitAPatch

[Expired for QEMU because there has been no activity for 60 days.]