From: Eric Bollengier Date: Wed, 2 Jul 2014 16:05:26 +0000 (+0200) Subject: Fix compilation of bsock.c when TLS is not available X-Git-Tag: Release-7.0.5~33 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=35c937efc2404e39b024552a2875b42178c133fe;p=bacula%2Fbacula Fix compilation of bsock.c when TLS is not available --- diff --git a/bacula/src/lib/bsock.c b/bacula/src/lib/bsock.c index 2aa9f095ed..1caba11d1c 100644 --- a/bacula/src/lib/bsock.c +++ b/bacula/src/lib/bsock.c @@ -904,6 +904,11 @@ int BSOCK::wait_data(int sec, int usec) return -1; /* error return */ default: b_errno = 0; +#ifdef HAVE_TLS + if (this->tls && !tls_bsock_probe(this)) { + continue; /* false alarm, maybe a session key negotiation in progress on the socket */ + } +#endif return 1; } } @@ -933,6 +938,15 @@ int BSOCK::wait_data_intr(int sec, int usec) return -1; /* error return */ default: b_errno = 0; +<<<<<<< HEAD +======= +#ifdef HAVE_TLS + if (this->tls && !tls_bsock_probe(this)) { + /* maybe a session key negotiation waked up the socket */ + return 0; + } +#endif +>>>>>>> 625e1f1... Fix compilation of bsock.c when TLS is not available break; } return 1;