]> git.proxmox.com Git - mirror_qemu.git/commit
io: add QIOChannelSocket class
authorDaniel P. Berrange <berrange@redhat.com>
Fri, 27 Feb 2015 16:19:33 +0000 (16:19 +0000)
committerDaniel P. Berrange <berrange@redhat.com>
Fri, 18 Dec 2015 12:18:31 +0000 (12:18 +0000)
commit559607ea173a0003efda7f884bec73b242f923fb
tree63e923e55537ea0add19a0a8bb7c1a238d6cb3e9
parentb02db2d9203ccfd1c26e55f7d975f0c05caee0ce
io: add QIOChannelSocket class

Implement a QIOChannel subclass that supports sockets I/O.
The implementation is able to manage a single socket file
descriptor, whether a TCP/UNIX listener, TCP/UNIX connection,
or a UDP datagram. It provides APIs which can listen and
connect either asynchronously or synchronously. Since there
is no asynchronous DNS lookup API available, it uses the
QIOTask helper for spawning a background thread to ensure
non-blocking operation.

Signed-off-by: Daniel P. Berrange <berrange@redhat.com>
13 files changed:
configure
include/io/channel-socket.h [new file with mode: 0644]
include/qemu/sockets.h
io/Makefile.objs
io/channel-socket.c [new file with mode: 0644]
scripts/create_config
tests/.gitignore
tests/Makefile
tests/io-channel-helpers.c [new file with mode: 0644]
tests/io-channel-helpers.h [new file with mode: 0644]
tests/test-io-channel-socket.c [new file with mode: 0644]
trace-events
util/qemu-sockets.c