aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPhillip Lougher <phillip@squashfs.org.uk>2014-09-12 23:28:59 +0100
committerPhillip Lougher <phillip@squashfs.org.uk>2014-09-12 23:28:59 +0100
commit27167b98babab9cc70b97ed3b0ae8a63378c14f7 (patch)
treeaa5128bae2b071e428ae9b5a0f88368f2b017b99
parentd033a7f78ac6b9d59338f2d2f16373659b29b77e (diff)
downloadsquashfs-tools-27167b98babab9cc70b97ed3b0ae8a63378c14f7.tar.gz
mksquashfs: fix progressbar for sort files
The progressbar was incorrectly enabled *after* writing files if sort files were used. This meant the progressbar would not be updated whilst files were being written to the filesystem. As this is the bulk of the work for Mksquashfs, this means the progressbar basically didn't appear to update whilst Mksquashfs was running, and then suddenly updated to 100% at the end of Mksquashfs. Signed-off-by: Phillip Lougher <phillip@squashfs.org.uk>
-rw-r--r--squashfs-tools/mksquashfs.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/squashfs-tools/mksquashfs.c b/squashfs-tools/mksquashfs.c
index 738bd7f..87b7d86 100644
--- a/squashfs-tools/mksquashfs.c
+++ b/squashfs-tools/mksquashfs.c
@@ -3179,10 +3179,11 @@ void dir_scan(squashfs_inode *inode, char *pathname,
queue_put(to_reader, root_dir);
+ set_progressbar_state(progress);
+
if(sorted)
sort_files_and_write(root_dir);
- set_progressbar_state(progress);
dir_scan7(inode, root_dir);
dir_ent->inode->inode = *inode;
dir_ent->inode->type = SQUASHFS_DIR_TYPE;
@@ -5089,7 +5090,7 @@ void calculate_queue_sizes(int mem, int *readq, int *fragq, int *bwriteq,
#define VERSION() \
- printf("mksquashfs version 4.3-git (2014/09/10)\n");\
+ printf("mksquashfs version 4.3-git (2014/09/12)\n");\
printf("copyright (C) 2014 Phillip Lougher "\
"<phillip@squashfs.org.uk>\n\n"); \
printf("This program is free software; you can redistribute it and/or"\