mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-05 00:33:55 -06:00
libqtest: add qtest_socket_server()
Add an API that returns a new UNIX domain socket in the listen state. The code for this was already there but only used internally in init_socket(). This new API will be used by vhost-user-blk-test. Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com> Reviewed-by: Thomas Huth <thuth@redhat.com> Reviewed-by: Wainer dos Santos Moschetta <wainersm@redhat.com> Message-Id: <20210223144653.811468-3-stefanha@redhat.com> Signed-off-by: Kevin Wolf <kwolf@redhat.com>
This commit is contained in:
parent
535255b438
commit
9fb7bb0698
2 changed files with 31 additions and 17 deletions
|
@ -132,6 +132,14 @@ void qtest_qmp_send(QTestState *s, const char *fmt, ...)
|
|||
void qtest_qmp_send_raw(QTestState *s, const char *fmt, ...)
|
||||
GCC_FMT_ATTR(2, 3);
|
||||
|
||||
/**
|
||||
* qtest_socket_server:
|
||||
* @socket_path: the UNIX domain socket path
|
||||
*
|
||||
* Create and return a listen socket file descriptor, or abort on failure.
|
||||
*/
|
||||
int qtest_socket_server(const char *socket_path);
|
||||
|
||||
/**
|
||||
* qtest_vqmp_fds:
|
||||
* @s: #QTestState instance to operate on.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue