summaryrefslogtreecommitdiff
path: root/trunk/src
diff options
context:
space:
mode:
Diffstat (limited to 'trunk/src')
-rwxr-xr-xtrunk/src/revdep-rebuild/revdep-rebuild8
1 files changed, 7 insertions, 1 deletions
diff --git a/trunk/src/revdep-rebuild/revdep-rebuild b/trunk/src/revdep-rebuild/revdep-rebuild
index ed1e11b..94a3f45 100755
--- a/trunk/src/revdep-rebuild/revdep-rebuild
+++ b/trunk/src/revdep-rebuild/revdep-rebuild
@@ -658,13 +658,19 @@ if $IS_REAL_MERGE ; then
echo
fi
+# Link file descriptor #6 with stdin
+exec 6<&0
+
# Run in background to correctly handle Ctrl-C
(
- EMERGE_DEFAULT_OPTS="" emerge --oneshot $EMERGE_OPTIONS $REBUILD_LIST
+ EMERGE_DEFAULT_OPTS="" emerge --oneshot $EMERGE_OPTIONS $REBUILD_LIST <&6
echo $? >$LLIST.6_status
) &
wait
+# Now restore stdin from fd #6, where it had been saved, and close fd #6 ( 6<&- ) to free it for other processes to use.
+exec 0<&6 6<&-
+
#if $EXACT_EBUILDS ; then
# mv -i /usr/portage/profiles/package.mask.hidden /usr/portage/profiles/package.mask
# trap - SIGHUP SIGINT SIGQUIT SIGABRT SIGTERM