do not do utime() on links, it acts on link targets, and we don't want that.
rename link_name to link_target, less confusing this way.
This commit is contained in:
@ -10,11 +10,9 @@
|
||||
#define ARCHIVE_NOPRESERVE_OWN 32
|
||||
#define ARCHIVE_NOPRESERVE_PERM 64
|
||||
|
||||
//#include "libbb.h"
|
||||
|
||||
typedef struct file_headers_s {
|
||||
typedef struct file_header_t {
|
||||
char *name;
|
||||
char *link_name;
|
||||
char *link_target;
|
||||
off_t size;
|
||||
uid_t uid;
|
||||
gid_t gid;
|
||||
@ -23,9 +21,9 @@ typedef struct file_headers_s {
|
||||
dev_t device;
|
||||
} file_header_t;
|
||||
|
||||
typedef struct archive_handle_s {
|
||||
typedef struct archive_handle_t {
|
||||
/* define if the header and data component should be processed */
|
||||
char (*filter)(struct archive_handle_s *);
|
||||
char (*filter)(struct archive_handle_t *);
|
||||
llist_t *accept;
|
||||
/* List of files that have been rejected */
|
||||
llist_t *reject;
|
||||
@ -39,13 +37,13 @@ typedef struct archive_handle_s {
|
||||
void (*action_header)(const file_header_t *);
|
||||
|
||||
/* process the data component, e.g. extract to filesystem */
|
||||
void (*action_data)(struct archive_handle_s *);
|
||||
void (*action_data)(struct archive_handle_t *);
|
||||
|
||||
/* How to process any sub archive, e.g. get_header_tar_gz */
|
||||
char (*action_data_subarchive)(struct archive_handle_s *);
|
||||
char (*action_data_subarchive)(struct archive_handle_t *);
|
||||
|
||||
/* Contains the handle to a sub archive */
|
||||
struct archive_handle_s *sub_archive;
|
||||
struct archive_handle_t *sub_archive;
|
||||
|
||||
/* The raw stream as read from disk or stdin */
|
||||
int src_fd;
|
||||
@ -54,7 +52,7 @@ typedef struct archive_handle_s {
|
||||
off_t offset;
|
||||
|
||||
/* Function that skips data: read_by_char or read_by_skip */
|
||||
void (*seek)(const struct archive_handle_s *archive_handle, const unsigned int amount);
|
||||
void (*seek)(const struct archive_handle_t *archive_handle, const unsigned amount);
|
||||
|
||||
/* Temporary storage */
|
||||
char *buffer;
|
||||
@ -92,8 +90,8 @@ extern char get_header_tar_bz2(archive_handle_t *archive_handle);
|
||||
extern char get_header_tar_lzma(archive_handle_t *archive_handle);
|
||||
extern char get_header_tar_gz(archive_handle_t *archive_handle);
|
||||
|
||||
extern void seek_by_jump(const archive_handle_t *archive_handle, const unsigned int amount);
|
||||
extern void seek_by_read(const archive_handle_t *archive_handle, const unsigned int amount);
|
||||
extern void seek_by_jump(const archive_handle_t *archive_handle, const unsigned amount);
|
||||
extern void seek_by_read(const archive_handle_t *archive_handle, const unsigned amount);
|
||||
|
||||
extern ssize_t archive_xread_all_eof(archive_handle_t *archive_handle, unsigned char *buf, size_t count);
|
||||
|
||||
|
Reference in New Issue
Block a user