diff options
author | Carl Worth <cworth@cworth.org> | 2006-03-23 15:00:40 -0800 |
---|---|---|
committer | Carl Worth <cworth@cworth.org> | 2006-03-23 15:00:40 -0800 |
commit | ec60bb0a606cadf3120d1cebc88e248a3e056c19 (patch) | |
tree | 51e2a4f461e323fd077c770d08a50f6a51fae6fd /src/cairo-lzw.c | |
parent | cabe94a15c277bb8a5f0c71f25cc8bc9e22ecb41 (diff) | |
download | cairo-ec60bb0a606cadf3120d1cebc88e248a3e056c19.tar.gz |
Rename _cairo_compress_lzw to _cairo_lzw_compress and tighten the parameter list.
Diffstat (limited to 'src/cairo-lzw.c')
-rw-r--r-- | src/cairo-lzw.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/cairo-lzw.c b/src/cairo-lzw.c index bb764f3a8..a0d737e25 100644 --- a/src/cairo-lzw.c +++ b/src/cairo-lzw.c @@ -460,14 +460,14 @@ cl_hash (LZWCodecState* sp) */ void * -_cairo_compress_lzw (void *data, unsigned long data_size, unsigned long *compressed_size) +_cairo_lzw_compress (void *data, unsigned long *data_size_in_out) { LZWCodecState state; if (!LZWSetupEncode (&state)) goto bail0; - state.out_buffer_size = data_size/4; + state.out_buffer_size = *data_size_in_out/4; /* We need *some* space at least */ if (state.out_buffer_size < 256) state.out_buffer_size = 256; @@ -479,14 +479,14 @@ _cairo_compress_lzw (void *data, unsigned long data_size, unsigned long *compres state.out_buffer_bytes = 0; LZWPreEncode (&state); - if (!LZWEncode (&state, data, data_size)) + if (!LZWEncode (&state, data, *data_size_in_out)) goto bail2; if (!LZWPostEncode(&state)) goto bail2; LZWFreeEncode(&state); - *compressed_size = state.out_buffer_bytes; + *data_size_in_out = state.out_buffer_bytes; return state.out_buffer; bail2: |