summaryrefslogtreecommitdiff
path: root/zlib
diff options
context:
space:
mode:
authorAndrew Tridgell <tridge@samba.org>1998-05-30 02:07:36 +0000
committerAndrew Tridgell <tridge@samba.org>1998-05-30 02:07:36 +0000
commitd846b0987475dcad9ea45b5feb4eaa00b9f91d86 (patch)
treef42c72fc662131565f839d44cea5f868b5e3ee08 /zlib
parent1d3754aede7d43ec072dd5d4e6cec57094bcd85c (diff)
downloadrsync-d846b0987475dcad9ea45b5feb4eaa00b9f91d86.tar.gz
replace BAD with zBAD so it compiles on AIX
Diffstat (limited to 'zlib')
-rw-r--r--zlib/infblock.c14
-rw-r--r--zlib/inflate.c22
-rw-r--r--zlib/infutil.h2
3 files changed, 19 insertions, 19 deletions
diff --git a/zlib/infblock.c b/zlib/infblock.c
index f8940c7f..3d6701e2 100644
--- a/zlib/infblock.c
+++ b/zlib/infblock.c
@@ -176,7 +176,7 @@ int r;
break;
case 3: /* illegal */
DUMPBITS(3)
- s->mode = BAD;
+ s->mode = zBAD;
z->msg = (char*)"invalid block type";
r = Z_DATA_ERROR;
LEAVE
@@ -186,7 +186,7 @@ int r;
NEEDBITS(32)
if ((((~b) >> 16) & 0xffff) != (b & 0xffff))
{
- s->mode = BAD;
+ s->mode = zBAD;
z->msg = (char*)"invalid stored block lengths";
r = Z_DATA_ERROR;
LEAVE
@@ -219,7 +219,7 @@ int r;
#ifndef PKZIP_BUG_WORKAROUND
if ((t & 0x1f) > 29 || ((t >> 5) & 0x1f) > 29)
{
- s->mode = BAD;
+ s->mode = zBAD;
z->msg = (char*)"too many length or distance symbols";
r = Z_DATA_ERROR;
LEAVE
@@ -252,7 +252,7 @@ int r;
ZFREE(z, s->sub.trees.blens);
r = t;
if (r == Z_DATA_ERROR)
- s->mode = BAD;
+ s->mode = zBAD;
LEAVE
}
s->sub.trees.index = 0;
@@ -289,7 +289,7 @@ int r;
(c == 16 && i < 1))
{
ZFREE(z, s->sub.trees.blens);
- s->mode = BAD;
+ s->mode = zBAD;
z->msg = (char*)"invalid bit length repeat";
r = Z_DATA_ERROR;
LEAVE
@@ -317,7 +317,7 @@ int r;
if (t != Z_OK)
{
if (t == (uInt)Z_DATA_ERROR)
- s->mode = BAD;
+ s->mode = zBAD;
r = t;
LEAVE
}
@@ -361,7 +361,7 @@ int r;
case DONE:
r = Z_STREAM_END;
LEAVE
- case BAD:
+ case zBAD:
r = Z_DATA_ERROR;
LEAVE
default:
diff --git a/zlib/inflate.c b/zlib/inflate.c
index 32e9b8de..c6eac9a3 100644
--- a/zlib/inflate.c
+++ b/zlib/inflate.c
@@ -22,7 +22,7 @@ typedef enum {
CHECK2, /* two check bytes to go */
CHECK1, /* one check byte to go */
DONE, /* finished check, done */
- BAD} /* got an error--stay here */
+ zBAD} /* got an error--stay here */
inflate_mode;
/* inflate private state */
@@ -38,7 +38,7 @@ struct internal_state {
uLong was; /* computed check value */
uLong need; /* stream check value */
} check; /* if CHECK, check values to compare */
- uInt marker; /* if BAD, inflateSync's marker bytes count */
+ uInt marker; /* if zBAD, inflateSync's marker bytes count */
} sub; /* submode */
/* mode independent information */
@@ -164,14 +164,14 @@ int f;
NEEDBYTE
if (((z->state->sub.method = NEXTBYTE) & 0xf) != Z_DEFLATED)
{
- z->state->mode = BAD;
+ z->state->mode = zBAD;
z->msg = (char*)"unknown compression method";
z->state->sub.marker = 5; /* can't try inflateSync */
break;
}
if ((z->state->sub.method >> 4) + 8 > z->state->wbits)
{
- z->state->mode = BAD;
+ z->state->mode = zBAD;
z->msg = (char*)"invalid window size";
z->state->sub.marker = 5; /* can't try inflateSync */
break;
@@ -182,7 +182,7 @@ int f;
b = NEXTBYTE;
if (((z->state->sub.method << 8) + b) % 31)
{
- z->state->mode = BAD;
+ z->state->mode = zBAD;
z->msg = (char*)"incorrect header check";
z->state->sub.marker = 5; /* can't try inflateSync */
break;
@@ -213,7 +213,7 @@ int f;
z->state->mode = DICT0;
return Z_NEED_DICT;
case DICT0:
- z->state->mode = BAD;
+ z->state->mode = zBAD;
z->msg = (char*)"need dictionary";
z->state->sub.marker = 0; /* can try inflateSync */
return Z_STREAM_ERROR;
@@ -221,7 +221,7 @@ int f;
r = inflate_blocks(z->state->blocks, z, r);
if (r == Z_DATA_ERROR)
{
- z->state->mode = BAD;
+ z->state->mode = zBAD;
z->state->sub.marker = 0; /* can try inflateSync */
break;
}
@@ -255,7 +255,7 @@ int f;
if (z->state->sub.check.was != z->state->sub.check.need)
{
- z->state->mode = BAD;
+ z->state->mode = zBAD;
z->msg = (char*)"incorrect data check";
z->state->sub.marker = 5; /* can't try inflateSync */
break;
@@ -264,7 +264,7 @@ int f;
z->state->mode = DONE;
case DONE:
return Z_STREAM_END;
- case BAD:
+ case zBAD:
return Z_DATA_ERROR;
default:
return Z_STREAM_ERROR;
@@ -310,9 +310,9 @@ z_streamp z;
/* set up */
if (z == Z_NULL || z->state == Z_NULL)
return Z_STREAM_ERROR;
- if (z->state->mode != BAD)
+ if (z->state->mode != zBAD)
{
- z->state->mode = BAD;
+ z->state->mode = zBAD;
z->state->sub.marker = 0;
}
if ((n = z->avail_in) == 0)
diff --git a/zlib/infutil.h b/zlib/infutil.h
index bc96d111..c5748e1e 100644
--- a/zlib/infutil.h
+++ b/zlib/infutil.h
@@ -21,7 +21,7 @@ typedef enum {
CODES, /* processing fixed or dynamic block */
DRY, /* output remaining window bytes */
DONE, /* finished last block, done */
- BAD} /* got a data error--stuck here */
+ zBAD} /* got a data error--stuck here */
inflate_block_mode;
/* inflate blocks semi-private state */