From 57d77eab32c01cd7572a11f76480a3724d09c029 Mon Sep 17 00:00:00 2001 From: Chantry Xavier Date: Sat, 7 Jul 2007 17:11:18 +0200 Subject: libalpm/trans.c : exit the forked process correctly in case of errors. Signed-off-by: Chantry Xavier --- lib/libalpm/trans.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'lib/libalpm') diff --git a/lib/libalpm/trans.c b/lib/libalpm/trans.c index 5d62e8e8..d0deb5ca 100644 --- a/lib/libalpm/trans.c +++ b/lib/libalpm/trans.c @@ -639,11 +639,11 @@ int _alpm_runscriptlet(const char *root, const char *installfn, _alpm_log(PM_LOG_DEBUG, _("chrooting in %s"), root); if(chroot(root) != 0) { _alpm_log(PM_LOG_ERROR, _("could not change the root directory (%s)"), strerror(errno)); - return(1); + exit(1); } if(chdir("/") != 0) { _alpm_log(PM_LOG_ERROR, _("could not change directory to / (%s)"), strerror(errno)); - return(1); + exit(1); } umask(0022); _alpm_log(PM_LOG_DEBUG, _("executing \"%s\""), cmdline); -- cgit v1.2.3-24-g4f1b