summaryrefslogtreecommitdiffstats
path: root/lsinitcpio
diff options
context:
space:
mode:
authorDave Reisner <dreisner@archlinux.org>2014-12-07 16:19:54 +0100
committerDave Reisner <dreisner@archlinux.org>2014-12-28 23:45:31 +0100
commit9398ae7fcbc2af9c788089ba72ddcd610b8df3a9 (patch)
tree9e47b6810d3f34888c2ad50e85ae085c27d20e76 /lsinitcpio
parent514d5f1fa641b0bfc66d43f4c0c7e7830f747899 (diff)
downloadmkinitcpio-9398ae7fcbc2af9c788089ba72ddcd610b8df3a9.tar.gz
mkinitcpio-9398ae7fcbc2af9c788089ba72ddcd610b8df3a9.tar.xz
lsinitcpio: avoid setting TIMEFORMAT globally
Not that it really matters, but let's scope this to where we actually care for the modified time output.
Diffstat (limited to 'lsinitcpio')
-rwxr-xr-xlsinitcpio2
1 files changed, 1 insertions, 1 deletions
diff --git a/lsinitcpio b/lsinitcpio
index 9567b79..f54fa25 100755
--- a/lsinitcpio
+++ b/lsinitcpio
@@ -139,7 +139,7 @@ analyze_image() {
zsize=$(stat -c %s "$_image")
# calculate compression ratio
- TIMEFORMAT=%R decomptime=$({ time decomp "$_image" >/dev/null; } 2>&1)
+ decomptime=$(TIMEFORMAT=%R; { time decomp "$_image" >/dev/null; } 2>&1)
if [[ $_compress ]]; then
fullsize=$(decomp "$_image" | wc -c)
ratio=.$(( zsize * 1000 / fullsize % 1000 ))