[prev in list] [next in list] [prev in thread] [next in thread] 

List:       bash-bug
Subject:    Re: bash doesn't send SIGHUP to children
From:       Chet Ramey <chet.ramey () case ! edu>
Date:       2008-09-16 18:10:48
Message-ID: 080916181048.AA86118.SM () caleb ! INS ! CWRU ! Edu
[Download RAW message or body]

> After some further investigation it turned out that you also need to use
> a function in your bash scripts to reproduce the bug.
> 
> I have the following in my .bashrc
> mc () { MC=`/usr/bin/mc -P "$@"`; [ -n "$MC" ] && cd "$MC"; unset MC; }
> 
> This was the recommended way for mc to 'remember' the directory you've last 
> visited when you exited mc.

When I use this function, with bash-3.2.39 and whatever the current versions
of rxvt and mc are on Red Hat and Ubuntu, I get an mc error:

Cannot get terminal settings: Invalid argument (22)

(which is indeed EINVAL).  Unsurprising if its stdout is still the command
substitution pipe at that point.

Did you have any luck with the version of the function I sent that runs mc
in the foreground?

Chet

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer

Chet Ramey, ITS, CWRU    chet@case.edu    http://tiswww.tis.case.edu/~chet/



[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic