Description of problem: Bash core-dumps on "echo ${b##${$a}}" Version-Release number of selected component (if applicable): bash-3.2-9.fc7 How reproducible: always Steps to Reproduce: 1. $ a=/home 2. $ b=/home/pok/bla/ble 3. $ echo ${b#${$a}} Actual results: core-dump Expected results: only some error (I have mistakenly ran that, when I was searching for "${b#$a}")
Created attachment 154264 [details] bash-3.1-16.1 backtrace (I don't have direct access to rawhide, but it behaves same way there)
I can't reproduce this here on bash-3.2-9.fc7.i386 -- can you provide a complete test case please? Should 'a' or 'b' be defined in the environment, for example?
Hm, typo in reproduce steps :) Please run this simple script #!/bin/bash a=adsf b=asdf echo ${b##${$a}} -A-
Thanks. Reproduced on FC-6.
echo ${$##${}} is enough as well.
Great, seems to be fixed in a current package. I do not see a reason for back-porting the patch because of low severity of the bug => closing. $ a=/home $ b=/home/pok/bla/ble $ echo ${b##${$a}} bash: ${$a}: bad substitution $ rpm -q bash bash-3.2-18.fc8 Thanks, Jan