chardev: honour the reconnect setting in tcp_chr_wait_connected
commit25d93b6a116fcef9b4c7c7dcea2fab90dd7c88b5
authorDaniel P. Berrangé <berrange@redhat.com>
Mon, 11 Feb 2019 18:24:38 +0000 (11 18:24 +0000)
committerMarc-André Lureau <marcandre.lureau@redhat.com>
Tue, 12 Feb 2019 16:35:56 +0000 (12 17:35 +0100)
tree7c1ef22852d6252d18a0303b744f0d2c0dcca359
parent32423ccaa1fb4d4777dbc4e3e3da331a1616a489
chardev: honour the reconnect setting in tcp_chr_wait_connected

If establishing a client connection fails, the tcp_chr_wait_connected
method should sleep for the reconnect timeout and then retry the
attempt. This ensures the callers don't immediately abort with an
error when the initial connection fails.

Reviewed-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
Message-Id: <20190211182442.8542-13-berrange@redhat.com>
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
chardev/char-socket.c