diff options
author | Daniil Baturin <daniil@baturin.org> | 2019-04-14 12:08:47 +0200 |
---|---|---|
committer | Daniil Baturin <daniil@baturin.org> | 2019-04-14 12:09:09 +0200 |
commit | 2fa8ec7f39ed8f3d21bd1f9e55add695aa2b2de6 (patch) | |
tree | 7c3201de7f24da6570fa8b428160f1be5cb8de2f /scripts | |
parent | 5356c3d5cd2a625840599f59f21c4088e150ae00 (diff) | |
download | vyatta-cfg-2fa8ec7f39ed8f3d21bd1f9e55add695aa2b2de6.tar.gz vyatta-cfg-2fa8ec7f39ed8f3d21bd1f9e55add695aa2b2de6.zip |
T1273: shorten the debug check.
Diffstat (limited to 'scripts')
-rwxr-xr-x | scripts/vyatta-boot-config-loader | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/scripts/vyatta-boot-config-loader b/scripts/vyatta-boot-config-loader index b445d9e..b242b78 100755 --- a/scripts/vyatta-boot-config-loader +++ b/scripts/vyatta-boot-config-loader @@ -16,13 +16,12 @@ do_log () { do_commit () { # Check if debug is enabled in the kernel command line - if [ ! grep vyos-debug /proc/cmdline > /dev/null ]; then - debug="" + grep vyos-debug /proc/cmdline > /dev/null + if [ $? == 0 ]; then + VYOS_DEBUG=$debug $COMMIT "$@" >>$COMMIT_LOG else - debug="yes" + $COMMIT "$@" >>$COMMIT_LOG fi - - VYOS_DEBUG=$debug $COMMIT "$@" >>$COMMIT_LOG } trace () { |