From 1ae8fbbdc6f8824f5188ed7e190ebfa36eb9ffee Mon Sep 17 00:00:00 2001 From: Kern Sibbald Date: Wed, 22 Oct 2008 18:52:59 +0000 Subject: [PATCH] Eliminate a couple of compiler warnings git-svn-id: https://bacula.svn.sourceforge.net/svnroot/bacula/trunk@7878 91ce42f0-d328-0410-95d8-f526ca767f89 --- bacula/src/filed/backup.c | 4 ++-- bacula/src/filed/verify.c | 4 ++-- bacula/src/lib/base64.c | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/bacula/src/filed/backup.c b/bacula/src/filed/backup.c index 07bbc264d1..9525a0579c 100644 --- a/bacula/src/filed/backup.c +++ b/bacula/src/filed/backup.c @@ -832,8 +832,8 @@ int send_data(JCR *jcr, int stream, FF_PKT *ff_pkt, DIGEST *digest, if (ff_pkt->flags & FO_SPARSE) { ser_declare; bool allZeros = false; - if (sd->msglen == rsize && - fileAddr+sd->msglen < (uint64_t)ff_pkt->statp.st_size || + if ((sd->msglen == rsize && + fileAddr+sd->msglen < (uint64_t)ff_pkt->statp.st_size) || ((ff_pkt->type == FT_RAW || ff_pkt->type == FT_FIFO) && (uint64_t)ff_pkt->statp.st_size == 0)) { allZeros = is_buf_zero(rbuf, rsize); diff --git a/bacula/src/filed/verify.c b/bacula/src/filed/verify.c index 424f178f62..257a51618d 100644 --- a/bacula/src/filed/verify.c +++ b/bacula/src/filed/verify.c @@ -347,8 +347,8 @@ static int read_digest(BFILE *bfd, DIGEST *digest, JCR *jcr) /* Check for sparse blocks */ if (ff_pkt->flags & FO_SPARSE) { bool allZeros = false; - if (n == bufsiz && - fileAddr+n < (uint64_t)ff_pkt->statp.st_size || + if ((n == bufsiz && + fileAddr+n < (uint64_t)ff_pkt->statp.st_size) || ((ff_pkt->type == FT_RAW || ff_pkt->type == FT_FIFO) && (uint64_t)ff_pkt->statp.st_size == 0)) { allZeros = is_buf_zero(buf, bufsiz); diff --git a/bacula/src/lib/base64.c b/bacula/src/lib/base64.c index c2d39dc3dd..87ab2c327d 100644 --- a/bacula/src/lib/base64.c +++ b/bacula/src/lib/base64.c @@ -177,7 +177,7 @@ bin_to_base64(char *buf, int buflen, char *bin, int binlen, int compatible) if (rem && j < buflen) { mask = (1 << rem) - 1; if (compatible) { - buf[j++] = base64_digits[(reg & mask) << 6 - rem]; + buf[j++] = base64_digits[(reg & mask) << (6 - rem)]; } else { buf[j++] = base64_digits[reg & mask]; } -- 2.39.5