|
| From: | Telychko |
| Subject: | expansion and redirections |
| Date: | Wed, 02 Oct 2013 17:25:47 +0300 |
| User-agent: | Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20130925 Thunderbird/17.0.8 |
Hi. Recently i found this feature(or bug): its reproduce interactively $exec 3</dev/zero # open /dev/zero on 3 $VAR=3 # have some variable with file descriptor $exec $VAR<&- # trying to close previously opened file descriptor bash: exec: 3: not found so we have expansion $exec $VAR<&- --> $exec 3 <&- ... why not $exec 3<&- $exec 3<&- # close normally Best regards.
| [Prev in Thread] | Current Thread | [Next in Thread] |