.comment-link {margin-left:.6em;}

Linux stories... and more

Monday, November 07, 2005

Embarassing bash

About three month ago I've discovered an interesting way to render bash shell unusable. Consider the following very simple bash script:
for i in 1 2 3; do
return
done

Put this script in the file, say, sourceme. Next, if you do the following:
#> source source
#> sleep 10

... Now hit CTRL-Z to suspend the sleep ...
At this point, the shell starts to behave very strangely. Lets just say that ls /tmp (or anything else) does not show anything.

I've send the message to bash-bug mailing list, reporting the problem to X, but there was no a single reply.

Update 23.11.2005:
bash guys have finally replied, saying that the bug has been confirmed and will be fixed in release 3.1.

0 Comments:

Post a Comment

<< Home