diff options
Diffstat (limited to 'xdelta3/xdelta3-fgk.h')
-rw-r--r-- | xdelta3/xdelta3-fgk.h | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/xdelta3/xdelta3-fgk.h b/xdelta3/xdelta3-fgk.h index 7011500..81d5e7e 100644 --- a/xdelta3/xdelta3-fgk.h +++ b/xdelta3/xdelta3-fgk.h | |||
@@ -109,7 +109,7 @@ static fgk_stream* fgk_alloc (xd3_stream *stream /*, usize_t alpha | |||
109 | static int fgk_init (xd3_stream *stream, | 109 | static int fgk_init (xd3_stream *stream, |
110 | fgk_stream *h, | 110 | fgk_stream *h, |
111 | int is_encode); | 111 | int is_encode); |
112 | static int fgk_encode_data (fgk_stream *h, | 112 | static usize_t fgk_encode_data (fgk_stream *h, |
113 | usize_t n); | 113 | usize_t n); |
114 | static inline fgk_bit fgk_get_encoded_bit (fgk_stream *h); | 114 | static inline fgk_bit fgk_get_encoded_bit (fgk_stream *h); |
115 | 115 | ||
@@ -125,7 +125,7 @@ static int xd3_encode_fgk (xd3_stream *stream, | |||
125 | 125 | ||
126 | static inline int fgk_decode_bit (fgk_stream *h, | 126 | static inline int fgk_decode_bit (fgk_stream *h, |
127 | fgk_bit b); | 127 | fgk_bit b); |
128 | static int fgk_decode_data (fgk_stream *h); | 128 | static usize_t fgk_decode_data (fgk_stream *h); |
129 | static void fgk_destroy (xd3_stream *stream, | 129 | static void fgk_destroy (xd3_stream *stream, |
130 | fgk_stream *h); | 130 | fgk_stream *h); |
131 | 131 | ||
@@ -234,7 +234,7 @@ static void fgk_swap_ptrs(fgk_node **one, fgk_node **two) | |||
234 | 234 | ||
235 | /* Takes huffman transmitter h and n, the nth elt in the alphabet, and | 235 | /* Takes huffman transmitter h and n, the nth elt in the alphabet, and |
236 | * returns the number of required to encode n. */ | 236 | * returns the number of required to encode n. */ |
237 | static int fgk_encode_data (fgk_stream* h, usize_t n) | 237 | static usize_t fgk_encode_data (fgk_stream* h, usize_t n) |
238 | { | 238 | { |
239 | fgk_node *target_ptr = h->alphabet + n; | 239 | fgk_node *target_ptr = h->alphabet + n; |
240 | 240 | ||
@@ -249,8 +249,8 @@ static int fgk_encode_data (fgk_stream* h, usize_t n) | |||
249 | * is not neccesary to encode these bits. */ | 249 | * is not neccesary to encode these bits. */ |
250 | if (IS_ADAPTIVE && target_ptr->weight == 0) | 250 | if (IS_ADAPTIVE && target_ptr->weight == 0) |
251 | { | 251 | { |
252 | unsigned int where, shift; | 252 | usize_t where, shift; |
253 | int bits; | 253 | usize_t bits; |
254 | 254 | ||
255 | where = fgk_find_nth_zero(h, n); | 255 | where = fgk_find_nth_zero(h, n); |
256 | shift = 1; | 256 | shift = 1; |
@@ -734,7 +734,7 @@ static usize_t fgk_nth_zero (fgk_stream* h, usize_t n) | |||
734 | * alphabet otherwise this returns 0, indicating more bits are | 734 | * alphabet otherwise this returns 0, indicating more bits are |
735 | * required. | 735 | * required. |
736 | */ | 736 | */ |
737 | static int fgk_decode_data (fgk_stream* h) | 737 | static usize_t fgk_decode_data (fgk_stream* h) |
738 | { | 738 | { |
739 | usize_t elt = (usize_t)(h->decode_ptr - h->alphabet); | 739 | usize_t elt = (usize_t)(h->decode_ptr - h->alphabet); |
740 | 740 | ||