summaryrefslogtreecommitdiffhomepage
path: root/include
diff options
context:
space:
mode:
authorDenys Vlasenko <vda.linux@googlemail.com>2009-08-28 21:09:51 +0200
committerDenys Vlasenko <vda.linux@googlemail.com>2009-08-28 21:09:51 +0200
commit0a130d510dc5272dc2fc7bc5a116f0694c8bd2a9 (patch)
tree029e91a6302547df06524ae6d73ecb5b85e35360 /include
parent7f2149489fe62373a13792d3de6c33c39725c76c (diff)
rpm2cpio: handle unseekable input correctly
function old new delta data_skip 14 20 +6 seek_by_jump 67 72 +5 data_align 81 84 +3 seek_by_read 20 19 -1 skip_header 99 94 -5 rpm2cpio_main 183 177 -6 ------------------------------------------------------------------------------ (add/remove: 0/0 grow/shrink: 3/3 up/down: 14/-12) Total: 2 bytes Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
Diffstat (limited to 'include')
-rw-r--r--include/unarchive.h8
1 files changed, 4 insertions, 4 deletions
diff --git a/include/unarchive.h b/include/unarchive.h
index 682e810d5..d8cb2a081 100644
--- a/include/unarchive.h
+++ b/include/unarchive.h
@@ -60,8 +60,8 @@ typedef struct archive_handle_t {
/* Count the number of bytes processed */
off_t offset;
- /* Function that skips data: read_by_char or read_by_skip */
- void FAST_FUNC (*seek)(const struct archive_handle_t *archive_handle, const unsigned amount);
+ /* Function that skips data */
+ void FAST_FUNC (*seek)(int fd, off_t amount);
/* Temporary storage */
char *buffer;
@@ -107,8 +107,8 @@ extern char get_header_tar_gz(archive_handle_t *archive_handle) FAST_FUNC;
extern char get_header_tar_bz2(archive_handle_t *archive_handle) FAST_FUNC;
extern char get_header_tar_lzma(archive_handle_t *archive_handle) FAST_FUNC;
-extern void seek_by_jump(const archive_handle_t *archive_handle, unsigned amount) FAST_FUNC;
-extern void seek_by_read(const archive_handle_t *archive_handle, unsigned amount) FAST_FUNC;
+extern void seek_by_jump(int fd, off_t amount) FAST_FUNC;
+extern void seek_by_read(int fd, off_t amount) FAST_FUNC;
extern void data_align(archive_handle_t *archive_handle, unsigned boundary) FAST_FUNC;
extern const llist_t *find_list_entry(const llist_t *list, const char *filename) FAST_FUNC;