summaryrefslogtreecommitdiffstats
path: root/bin
diff options
context:
space:
mode:
authorRobert Schwebel <r.schwebel@pengutronix.de>2008-05-23 04:41:25 +0000
committerRobert Schwebel <r.schwebel@pengutronix.de>2008-05-23 04:41:25 +0000
commit2e14e3306923251dbdef7059f3db8cec5ed49e55 (patch)
tree78e903c866b5b963b8bf0f681fb56e99257a3237 /bin
parent6d278f7071237f8211247b2e88b260b7eb16bc8f (diff)
downloadptxdist-2e14e3306923251dbdef7059f3db8cec5ed49e55.tar.gz
ptxdist-2e14e3306923251dbdef7059f3db8cec5ed49e55.tar.xz
* ptxdist: In silent mode, we cannot redirect input. So use
oldconfig instead of silentoldconfig if somebody tries to automate us. git-svn-id: https://svn.pengutronix.de/svn/ptxdist/trunks/ptxdist-trunk@8214 33e552b5-05e3-0310-8538-816dae2090ed
Diffstat (limited to 'bin')
-rwxr-xr-xbin/ptxdist9
1 files changed, 8 insertions, 1 deletions
diff --git a/bin/ptxdist b/bin/ptxdist
index 44b073f5e..eef0b1e14 100755
--- a/bin/ptxdist
+++ b/bin/ptxdist
@@ -727,7 +727,14 @@ newpacket() {
}
oldconfig_action() {
- "${PTXDIST_TOPDIR}/scripts/kconfig/conf" -s "${kconfig}"
+ # In silent mode, we cannot redirect input. So use oldconfig
+ # instead of silentoldconfig if somebody tries to automate us.
+ tty -s
+ if [ "$?" = "0" ]; then
+ "${PTXDIST_TOPDIR}/scripts/kconfig/conf" -s "${kconfig}"
+ else
+ "${PTXDIST_TOPDIR}/scripts/kconfig/conf" -o "${kconfig}"
+ fi
}