diff options
author | Mattia Rizzolo <mattia@mapreri.org> | 2015-11-22 20:04:31 +0000 |
---|---|---|
committer | Mattia Rizzolo <mattia@mapreri.org> | 2015-11-22 20:04:31 +0000 |
commit | 91708724401f61b05f432185176066d1f5ec2ec0 (patch) | |
tree | 2c1904b59f6fd795e1460b810498872a246edeee | |
parent | c6dcd5e516f0de7199599ff69e55cb3525e7bec6 (diff) | |
download | pbuilder-91708724401f61b05f432185176066d1f5ec2ec0.tar pbuilder-91708724401f61b05f432185176066d1f5ec2ec0.tar.gz |
buildpackage: umount as the very last option, due keeping the bindmounts while executing the hooks
Closes: #805552
-rwxr-xr-x | pbuilder-buildpackage | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/pbuilder-buildpackage b/pbuilder-buildpackage index 54cf13e..ccd7eb7 100755 --- a/pbuilder-buildpackage +++ b/pbuilder-buildpackage @@ -180,11 +180,7 @@ else # build was successful fi -trap umountproc_cleanbuildplace_trap exit sighup sigpipe executehooks "B" -save_aptcache -trap cleanbuildplace_trap exit sighup sigpipe -umountproc if [ -d "${BUILDRESULT}" ]; then chown "${BUILDRESULTUID}:${BUILDRESULTGID}" "${BUILDPLACE}$BUILDDIR/"* @@ -203,6 +199,11 @@ else log.e "BUILDRESULT=[$BUILDRESULT] is not a directory." fi +# final cleanup +trap umountproc_cleanbuildplace_trap exit sighup sigpipe +save_aptcache +trap cleanbuildplace_trap exit sighup sigpipe +umountproc : cleanbuildplace trap - exit sighup sigpipe |