From: Kern Sibbald Date: Thu, 14 Apr 2016 13:59:17 +0000 (+0200) Subject: Tweak bsock msglen of zero loop X-Git-Tag: Release-7.4.1~24 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=7f8e0f3352ca2a16a00d30c0e9762c534233d2a2;p=bacula%2Fbacula Tweak bsock msglen of zero loop --- diff --git a/bacula/src/lib/bsock.c b/bacula/src/lib/bsock.c index ced11125ab..5cb5d63da4 100644 --- a/bacula/src/lib/bsock.c +++ b/bacula/src/lib/bsock.c @@ -483,7 +483,7 @@ bool BSOCK::fsend(const char *fmt, ...) va_start(arg_ptr, fmt); msglen = bvsnprintf(msg, maxlen, fmt, arg_ptr); va_end(arg_ptr); - if (msglen > 0 && msglen < (maxlen - 5)) { + if (msglen >= 0 && msglen < (maxlen - 5)) { break; } msg = realloc_pool_memory(msg, maxlen + maxlen / 2);