On 12/2/12 11:52 AM, Andrey Borzenkov wrote:
> I hit this problem in DKMS code and could reduce it to the following
> example:

Thanks for the report.  The problem has to do with state in the process
substitution subshell preventing it from using the temporary environment
for variable lookups.  It will be fixed in the next version.  I have
attached a patch; please let me know if it fixes the issue for you.

Chet
-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
                 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, ITS, CWRU    c...@case.edu    http://cnswww.cns.cwru.edu/~chet/
*** ../bash-4.2-patched/subst.c	2012-07-14 15:53:20.000000000 -0400
--- subst.c	2012-12-02 22:26:54.000000000 -0500
***************
*** 5125,5128 ****
--- 5129,5136 ----
  #endif /* HAVE_DEV_FD */
  
+   /* subshells shouldn't have this flag, which controls using the temporary
+      environment for variable lookups. */
+   expanding_redir = 0;
+ 
    result = parse_and_execute (string, "process substitution", (SEVAL_NONINT|SEVAL_NOHIST));
  

Reply via email to