enable setsid for job control in recovery shell (issue #382)

This commit is contained in:
Trammell hudson 2018-04-10 15:39:05 -04:00
parent 23e0dc84ef
commit b887104035
Failed to extract signature
2 changed files with 7 additions and 2 deletions

View File

@ -664,7 +664,7 @@ CONFIG_SETPRIV=y
CONFIG_FEATURE_SETPRIV_DUMP=y
CONFIG_FEATURE_SETPRIV_CAPABILITIES=y
CONFIG_FEATURE_SETPRIV_CAPABILITY_NAMES=y
# CONFIG_SETSID is not set
CONFIG_SETSID=y
# CONFIG_SWAPON is not set
# CONFIG_FEATURE_SWAPON_DISCARD is not set
# CONFIG_FEATURE_SWAPON_PRI is not set

View File

@ -22,7 +22,12 @@ recovery() {
fi
echo >&2 "!!!!! Starting recovery shell"
sleep 1
exec /bin/ash
if [ -x /bin/setsid ]; then
exec /bin/setsid -c /bin/ash
else
exec /bin/ash
fi
}
pause_recovery() {