mirror of
https://github.com/vdsm/virtual-dsm.git
synced 2025-11-14 05:53:42 +08:00
fix: Verify files are not empty (#689)
This commit is contained in:
@@ -21,7 +21,7 @@ fi
|
||||
|
||||
while true
|
||||
do
|
||||
if [ -f "$file" ]; then
|
||||
if [ -s "$file" ]; then
|
||||
bytes=$(du -sb "$file" | cut -f1)
|
||||
if (( bytes > 1000 )); then
|
||||
size=$(echo "$bytes" | numfmt --to=iec --suffix=B | sed -r 's/([A-Z])/ \1/')
|
||||
|
||||
Reference in New Issue
Block a user