OSDN Git Service

char-socket: update local address after listen
authorMarc-André Lureau <marcandre.lureau@redhat.com>
Tue, 20 Dec 2016 14:36:57 +0000 (15:36 +0100)
committerMarc-André Lureau <marcandre.lureau@redhat.com>
Thu, 4 May 2017 11:34:41 +0000 (15:34 +0400)
commitbc763d71440552b677bc372e8261b9d127330657
tree3db68e21a2a9394efdb5e32f972ad724081e408b
parentbbcde969b242fc4b3ab84097f7783cfe0920e69f
char-socket: update local address after listen

This is mainly useful to know the actual bound port when using port 0.

For example, when starting qemu with socket on port 0, before:
QEMU waiting for connection on: disconnected:tcp:localhost:0,server
After:
QEMU waiting for connection on: disconnected:tcp:localhost:32454,server

Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
chardev/char-socket.c