diff options
author | Zhijiang Hu <hu.zhijiang@zte.com.cn> | 2017-04-17 07:59:56 +0000 |
---|---|---|
committer | Gerrit Code Review <gerrit@opnfv.org> | 2017-04-17 07:59:56 +0000 |
commit | 12eaf7b46bec6d25caf0d2d58c7a1eb69f33a3d8 (patch) | |
tree | b6648607713e3819853c6aad08f697f6eb382526 /tools | |
parent | e88f7744d97fd940db2ffdda76ee1b12bc97a216 (diff) | |
parent | 6eaa8fc812ef8feeac5ec2f76c9fdc110b2b5c75 (diff) |
Merge "The image file is deleted mistakenly"
Diffstat (limited to 'tools')
-rwxr-xr-x | tools/daisy-img-modify.sh | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/tools/daisy-img-modify.sh b/tools/daisy-img-modify.sh index f172ceec..90910a14 100755 --- a/tools/daisy-img-modify.sh +++ b/tools/daisy-img-modify.sh @@ -211,9 +211,6 @@ cleanup() { kpartx -dv $raw_imgfile || eliminate fi rm -f $raw_imgfile - if [ -f $imgfile ]; then - rm -rf $imgfile - fi rm -rf $mountdir } @@ -239,6 +236,9 @@ error_trap() main() { cleanup + if [ -f $imgfile ]; then + rm -rf $imgfile + fi trap "error_trap" EXIT SIGTERM |