summaryrefslogtreecommitdiff
path: root/unpack
diff options
context:
space:
mode:
authorDavid Oberhollenzer <david.oberhollenzer@sigma-star.at>2019-09-20 22:26:56 +0200
committerDavid Oberhollenzer <david.oberhollenzer@sigma-star.at>2019-09-20 22:26:56 +0200
commit012a83c9466e8668fc08acb6a80fa4dd5c82997c (patch)
tree4cd6cb483db184e2fd560a48c3650431cb1fd5d3 /unpack
parent1a6b70f3702d3bdb0f1cb8e4669ec5ed21ea923b (diff)
Add sqfs_ prefix to data_reader_t & functions
Signed-off-by: David Oberhollenzer <david.oberhollenzer@sigma-star.at>
Diffstat (limited to 'unpack')
-rw-r--r--unpack/fill_files.c8
-rw-r--r--unpack/rdsquashfs.c12
-rw-r--r--unpack/rdsquashfs.h2
3 files changed, 11 insertions, 11 deletions
diff --git a/unpack/fill_files.c b/unpack/fill_files.c
index f98a801..2c20ab0 100644
--- a/unpack/fill_files.c
+++ b/unpack/fill_files.c
@@ -156,7 +156,7 @@ static int gen_file_list_dfs(const sqfs_tree_node_t *n)
return 0;
}
-static int fill_files(data_reader_t *data, int flags)
+static int fill_files(sqfs_data_reader_t *data, int flags)
{
size_t i;
int fd;
@@ -172,8 +172,8 @@ static int fill_files(data_reader_t *data, int flags)
if (!(flags & UNPACK_QUIET))
printf("unpacking %s\n", files[i].path);
- if (data_reader_dump(data, files[i].inode, fd, block_size,
- (flags & UNPACK_NO_SPARSE) == 0)) {
+ if (sqfs_data_reader_dump(data, files[i].inode, fd, block_size,
+ (flags & UNPACK_NO_SPARSE) == 0)) {
close(fd);
return -1;
}
@@ -185,7 +185,7 @@ static int fill_files(data_reader_t *data, int flags)
}
int fill_unpacked_files(size_t blk_sz, const sqfs_tree_node_t *root,
- data_reader_t *data, int flags)
+ sqfs_data_reader_t *data, int flags)
{
int status;
diff --git a/unpack/rdsquashfs.c b/unpack/rdsquashfs.c
index 29f9b79..7bb1ab4 100644
--- a/unpack/rdsquashfs.c
+++ b/unpack/rdsquashfs.c
@@ -11,11 +11,11 @@ int main(int argc, char **argv)
sqfs_xattr_reader_t *xattr = NULL;
sqfs_compressor_config_t cfg;
int status = EXIT_FAILURE;
+ sqfs_data_reader_t *data;
sqfs_dir_reader_t *dirrd;
sqfs_compressor_t *cmp;
sqfs_id_table_t *idtbl;
sqfs_tree_node_t *n;
- data_reader_t *data;
sqfs_super_t super;
sqfs_file_t *file;
options_t opt;
@@ -80,11 +80,11 @@ int main(int argc, char **argv)
goto out_id;
}
- data = data_reader_create(file, super.block_size, cmp);
+ data = sqfs_data_reader_create(file, super.block_size, cmp);
if (data == NULL)
goto out_dr;
- if (data_reader_load_fragment_table(data, &super))
+ if (sqfs_data_reader_load_fragment_table(data, &super))
goto out_data;
ret = sqfs_dir_reader_get_full_hierarchy(dirrd, idtbl, opt.cmdpath,
@@ -105,8 +105,8 @@ int main(int argc, char **argv)
goto out;
}
- if (data_reader_dump(data, n->inode, STDOUT_FILENO,
- super.block_size, false))
+ if (sqfs_data_reader_dump(data, n->inode, STDOUT_FILENO,
+ super.block_size, false))
goto out;
break;
case OP_UNPACK:
@@ -144,7 +144,7 @@ int main(int argc, char **argv)
out:
sqfs_dir_tree_destroy(n);
out_data:
- data_reader_destroy(data);
+ sqfs_data_reader_destroy(data);
out_dr:
sqfs_dir_reader_destroy(dirrd);
out_id:
diff --git a/unpack/rdsquashfs.h b/unpack/rdsquashfs.h
index e348293..dafb73d 100644
--- a/unpack/rdsquashfs.h
+++ b/unpack/rdsquashfs.h
@@ -72,7 +72,7 @@ int update_tree_attribs(sqfs_xattr_reader_t *xattr,
const sqfs_tree_node_t *root, int flags);
int fill_unpacked_files(size_t blk_sz, const sqfs_tree_node_t *root,
- data_reader_t *data, int flags);
+ sqfs_data_reader_t *data, int flags);
int describe_tree(const sqfs_tree_node_t *root, const char *unpack_root);