From e97ca08b2acabd6b2f327b44aa03670df929b770 Mon Sep 17 00:00:00 2001 From: Jacob Winther Date: Wed, 29 Jul 2009 14:14:31 -0700 Subject: functions: Add -- to stat_append printf printf causes scripts to fail when argument starts with a dash Calling stat_append "- hello" causes the following error: /etc/rc.d/functions: line 99: printf: - : invalid option printf: usage: printf [-v var] format [arguments] [FAIL] Ref: FS#15713 Signed-off-by: Aaron Griffin --- functions | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'functions') diff --git a/functions b/functions index ba37f57..1d51345 100644 --- a/functions +++ b/functions @@ -96,7 +96,7 @@ stat_busy() { stat_append() { printf "${RESTORE_POSITION}" - printf "${C_MAIN}${1}${C_CLEAR}" + printf -- "${C_MAIN}${1}${C_CLEAR}" printf "${SAVE_POSITION}" } -- cgit v1.2.3