Displaying 2 results from an estimated 2 matches for "rcv_buffer".
Did you mean:
recv_buffer
2015 Nov 04
2
Retrieving datas sent by host within the Guest
...tream socket");
20 exit(1);
21 }
I got ""binding stream socket Address already in use" when trying to bind the socket .
But If I use such kind of thing :
fd = open("/dev/virtio-ports/agent", O_RDWR | O_NONBLOCK);
ssize_t size = read(fd, &rcv_buffer, 100);
if(size >0) printf("Read length(%d) %s\n", size, rcv_buffer);
It works fine.
Is there any chance to be able to use socket stuff on Guest side or is there anything I misunderstand?
Thanks for help.
J.P.
J.P. Ribeauville
P: +33.(0).1.47.17.20.49
.
Puteaux 3 Etage 5...
2015 Nov 04
0
Re: Retrieving datas sent by host within the Guest
...e" when trying to bind the socket .
>
shouldn't you conect() instead of bind() ? Of course, open() should
write as well.
>
>But If I use such kind of thing :
>
> fd = open("/dev/virtio-ports/agent", O_RDWR | O_NONBLOCK);
> ssize_t size = read(fd, &rcv_buffer, 100);
> if(size >0) printf("Read length(%d) %s\n", size, rcv_buffer);
>
>It works fine.
>
>Is there any chance to be able to use socket stuff on Guest side or is there anything I misunderstand?
>
>Thanks for help.
>
>
>J.P.
>
>
>J.P. Ribeauv...