diff options
Diffstat (limited to 'include')
-rw-r--r-- | include/bb_archive.h | 24 |
1 files changed, 12 insertions, 12 deletions
diff --git a/include/bb_archive.h b/include/bb_archive.h index b82cfd83c..8a2dd2735 100644 --- a/include/bb_archive.h +++ b/include/bb_archive.h | |||
@@ -203,27 +203,27 @@ int read_bunzip(bunzip_data *bd, char *outbuf, int len) FAST_FUNC; | |||
203 | void dealloc_bunzip(bunzip_data *bd) FAST_FUNC; | 203 | void dealloc_bunzip(bunzip_data *bd) FAST_FUNC; |
204 | 204 | ||
205 | /* Meaning and direction (input/output) of the fields are transformer-specific */ | 205 | /* Meaning and direction (input/output) of the fields are transformer-specific */ |
206 | typedef struct transformer_aux_data_t { | 206 | typedef struct transformer_state_t { |
207 | smallint check_signature; /* most often referenced member */ | 207 | smallint check_signature; /* most often referenced member */ |
208 | off_t bytes_out; | 208 | off_t bytes_out; |
209 | off_t bytes_in; /* used in unzip code only: needs to know packed size */ | 209 | off_t bytes_in; /* used in unzip code only: needs to know packed size */ |
210 | uint32_t crc32; | 210 | uint32_t crc32; |
211 | time_t mtime; /* gunzip code may set this on exit */ | 211 | time_t mtime; /* gunzip code may set this on exit */ |
212 | } transformer_aux_data_t; | 212 | } transformer_state_t; |
213 | 213 | ||
214 | void init_transformer_aux_data(transformer_aux_data_t *aux) FAST_FUNC; | 214 | void init_transformer_state(transformer_state_t *xstate) FAST_FUNC; |
215 | int FAST_FUNC check_signature16(transformer_aux_data_t *aux, int src_fd, unsigned magic16) FAST_FUNC; | 215 | int FAST_FUNC check_signature16(transformer_state_t *xstate, int src_fd, unsigned magic16) FAST_FUNC; |
216 | 216 | ||
217 | IF_DESKTOP(long long) int inflate_unzip(transformer_aux_data_t *aux, int src_fd, int dst_fd) FAST_FUNC; | 217 | IF_DESKTOP(long long) int inflate_unzip(transformer_state_t *xstate, int src_fd, int dst_fd) FAST_FUNC; |
218 | IF_DESKTOP(long long) int unpack_Z_stream(transformer_aux_data_t *aux, int src_fd, int dst_fd) FAST_FUNC; | 218 | IF_DESKTOP(long long) int unpack_Z_stream(transformer_state_t *xstate, int src_fd, int dst_fd) FAST_FUNC; |
219 | IF_DESKTOP(long long) int unpack_gz_stream(transformer_aux_data_t *aux, int src_fd, int dst_fd) FAST_FUNC; | 219 | IF_DESKTOP(long long) int unpack_gz_stream(transformer_state_t *xstate, int src_fd, int dst_fd) FAST_FUNC; |
220 | IF_DESKTOP(long long) int unpack_bz2_stream(transformer_aux_data_t *aux, int src_fd, int dst_fd) FAST_FUNC; | 220 | IF_DESKTOP(long long) int unpack_bz2_stream(transformer_state_t *xstate, int src_fd, int dst_fd) FAST_FUNC; |
221 | IF_DESKTOP(long long) int unpack_lzma_stream(transformer_aux_data_t *aux, int src_fd, int dst_fd) FAST_FUNC; | 221 | IF_DESKTOP(long long) int unpack_lzma_stream(transformer_state_t *xstate, int src_fd, int dst_fd) FAST_FUNC; |
222 | IF_DESKTOP(long long) int unpack_xz_stream(transformer_aux_data_t *aux, int src_fd, int dst_fd) FAST_FUNC; | 222 | IF_DESKTOP(long long) int unpack_xz_stream(transformer_state_t *xstate, int src_fd, int dst_fd) FAST_FUNC; |
223 | 223 | ||
224 | char* append_ext(char *filename, const char *expected_ext) FAST_FUNC; | 224 | char* append_ext(char *filename, const char *expected_ext) FAST_FUNC; |
225 | int bbunpack(char **argv, | 225 | int bbunpack(char **argv, |
226 | IF_DESKTOP(long long) int FAST_FUNC (*unpacker)(transformer_aux_data_t *aux), | 226 | IF_DESKTOP(long long) int FAST_FUNC (*unpacker)(transformer_state_t *xstate), |
227 | char* FAST_FUNC (*make_new_name)(char *filename, const char *expected_ext), | 227 | char* FAST_FUNC (*make_new_name)(char *filename, const char *expected_ext), |
228 | const char *expected_ext | 228 | const char *expected_ext |
229 | ) FAST_FUNC; | 229 | ) FAST_FUNC; |
@@ -232,7 +232,7 @@ void check_errors_in_children(int signo); | |||
232 | #if BB_MMU | 232 | #if BB_MMU |
233 | void open_transformer(int fd, | 233 | void open_transformer(int fd, |
234 | int check_signature, | 234 | int check_signature, |
235 | IF_DESKTOP(long long) int FAST_FUNC (*transformer)(transformer_aux_data_t *aux, int src_fd, int dst_fd) | 235 | IF_DESKTOP(long long) int FAST_FUNC (*transformer)(transformer_state_t *xstate, int src_fd, int dst_fd) |
236 | ) FAST_FUNC; | 236 | ) FAST_FUNC; |
237 | #define open_transformer_with_sig(fd, transformer, transform_prog) open_transformer((fd), 1, (transformer)) | 237 | #define open_transformer_with_sig(fd, transformer, transform_prog) open_transformer((fd), 1, (transformer)) |
238 | #define open_transformer_with_no_sig(fd, transformer) open_transformer((fd), 0, (transformer)) | 238 | #define open_transformer_with_no_sig(fd, transformer) open_transformer((fd), 0, (transformer)) |