https://bugzilla.novell.com/show_bug.cgi?id=383486
User suse-beta@cboltz.de added comment
https://bugzilla.novell.com/show_bug.cgi?id=383486#c8
--- Comment #8 from Christian Boltz 2008-04-28 12:00:17 MST ---
Sorry for testing with "sh" - this indeed caused the wrong result.
I tested again with the "." method - it seems that trying to change already set
readonly variables causes the problem.
# cat bash_completion_minimal # first lines of bash_completion + debugging
{
# These declarations must go within braces in order to be able to silence
# readonly variable errors.
echo "test one $?"
BASH_COMPLETION="${BASH_COMPLETION:-/etc/bash_completion}"
echo "test two $?"
BASH_COMPLETION_DIR="${BASH_COMPLETION_DIR:=/etc/bash_completion.d}"
echo "test three $?"
} || :
readonly BASH_COMPLETION BASH_COMPLETION_DIR
# . bash_completion_minimal
test one 0
bash: BASH_COMPLETION: readonly variable
# echo $?
1
BTW: Aaron, you might want to use "set -x" before running the script ;-)
--
Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.