aboutsummaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorDenis Vlasenko <vda.linux@googlemail.com>2007-01-05 23:56:53 +0000
committerDenis Vlasenko <vda.linux@googlemail.com>2007-01-05 23:56:53 +0000
commitcd42cb8df066ffd4449af6de168190669dad4453 (patch)
tree10731cda21479451f3ca050c9f030b682a1d99aa /include
parent447b543eafeed669112085fc877a29c726e1947e (diff)
downloadbusybox-cd42cb8df066ffd4449af6de168190669dad4453.tar.gz
do not expose internal state of [g]zip unpacker.
fix memory leak in inflate_gunzip.
Diffstat (limited to 'include')
-rw-r--r--include/unarchive.h15
1 files changed, 7 insertions, 8 deletions
diff --git a/include/unarchive.h b/include/unarchive.h
index 843f68f73..5e87d088e 100644
--- a/include/unarchive.h
+++ b/include/unarchive.h
@@ -65,10 +65,6 @@ typedef struct archive_handle_s {
} archive_handle_t;
-extern uint32_t gunzip_crc;
-extern off_t gunzip_bytes_out;
-
-
extern archive_handle_t *init_handle(void);
extern char filter_accept_all(archive_handle_t *archive_handle);
@@ -106,14 +102,17 @@ extern const llist_t *find_list_entry(const llist_t *list, const char *filename)
extern const llist_t *find_list_entry2(const llist_t *list, const char *filename);
extern USE_DESKTOP(long long) int uncompressStream(int src_fd, int dst_fd);
-extern void inflate_init(unsigned int bufsize);
-extern void inflate_cleanup(void);
-extern USE_DESKTOP(long long) int inflate_unzip(int in, int out);
+
+typedef struct inflate_unzip_result {
+ off_t bytes_out;
+ uint32_t crc;
+} inflate_unzip_result;
+
+extern USE_DESKTOP(long long) int inflate_unzip(inflate_unzip_result *res, unsigned bufsize, int in, int out);
extern USE_DESKTOP(long long) int inflate_gunzip(int in, int out);
extern USE_DESKTOP(long long) int unlzma(int src_fd, int dst_fd);
extern int open_transformer(int src_fd,
USE_DESKTOP(long long) int (*transformer)(int src_fd, int dst_fd));
-
#endif