bash source question & suggestion?

2016-02-09 Thread Linda Walsh
At various times I see people contributing code to bash. I was wondering if it might be possible to use C++ in some patches or new files? I know that the kernel, and the glib include files go to extra pain to declare 'C' functions when using C++ where those C function need to be called from C++.

Re: bug when 'cd ..' to a directory who's parent has been deleted

2016-02-09 Thread Odd Arne Beck
Den 09.02.2016 20:55, skrev Chet Ramey: On 2/9/16 2:43 PM, Odd Arne Beck wrote: Chet Ramey: I fear you have misunderstood me (OP). What I meant was, exactly as you say, the parent AND current folder has been removed, but from a different shell. It's also reprodusable if you do something like th

Re: bug when 'cd ..' to a directory who's parent has been deleted

2016-02-09 Thread Odd Arne Beck
Den 09.02.2016 20:15, skrev Chet Ramey: -BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On 2/9/16 1:54 PM, Mike Frysinger wrote: On 09 Feb 2016 07:47, Chet Ramey wrote: On 2/9/16 2:10 AM, Mike Frysinger wrote: It's still an unlikely scenario. fwiw, i see it semi often when dealing with build s

Re: bug when 'cd ..' to a directory who's parent has been deleted

2016-02-09 Thread Linda Walsh
Andreas Schwab wrote: Linda Walsh writes: You can't open a file handle on a file. The fd comes from some OS call associating it with the file on disk (or some other connection). You have to de

Re: bug when 'cd ..' to a directory who's parent has been deleted

2016-02-09 Thread Chet Ramey
On 2/9/16 2:43 PM, Odd Arne Beck wrote: > Chet Ramey: I fear you have misunderstood me (OP). What I meant was, > exactly as you say, the parent AND current folder has been removed, but > from a different shell. It's also reprodusable if you do something like > this from within the same shell: > >

Re: bug when 'cd ..' to a directory who's parent has been deleted

2016-02-09 Thread Chet Ramey
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On 2/9/16 1:54 PM, Mike Frysinger wrote: > On 09 Feb 2016 07:47, Chet Ramey wrote: >> On 2/9/16 2:10 AM, Mike Frysinger wrote: It's still an unlikely scenario. >>> >>> fwiw, i see it semi often when dealing with build systems: >> >> The unlikely s

Re: bug when 'cd ..' to a directory who's parent has been deleted

2016-02-09 Thread Mike Frysinger
On 09 Feb 2016 07:47, Chet Ramey wrote: > On 2/9/16 2:10 AM, Mike Frysinger wrote: > >> It's still an unlikely scenario. > > > > fwiw, i see it semi often when dealing with build systems: > > The unlikely scenario is somehow deleting a non-empty directory, as the OP > implied in his first posting

Re: bug when 'cd ..' to a directory who's parent has been deleted

2016-02-09 Thread Chet Ramey
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On 2/9/16 2:10 AM, Mike Frysinger wrote: >> It's still an unlikely scenario. > > fwiw, i see it semi often when dealing with build systems: The unlikely scenario is somehow deleting a non-empty directory, as the OP implied in his first posting. -

Re: Bogus value of variable BASH

2016-02-09 Thread Chet Ramey
On 2/8/16 7:09 PM, David Hunt wrote: > Bash Version: 4.3 > Patch Level: 11 > Release Status: release > > Description: > On my notebook running Ubuntu 14.04.3 LTS /bin/sh points to dash, not > bash. > To get sh behaviour from bash I use the command `exec -a sh /bin/bash'. > When

Re: bug when 'cd ..' to a directory who's parent has been deleted

2016-02-09 Thread Mike Frysinger
On 09 Feb 2016 12:22, Odd Beck wrote: > We all use our number crunching slaves differently, so I have never seen it > until yesterday, but if it's common then there might be a valid reason to > investigate this issue and maybe do some bugfixin' :) sorry, but my posting wasn't to say i think the cu

Re: bug when 'cd ..' to a directory who's parent has been deleted

2016-02-09 Thread Odd Beck
We all use our number crunching slaves differently, so I have never seen it until yesterday, but if it's common then there might be a valid reason to investigate this issue and maybe do some bugfixin' :) On Tue, Feb 9, 2016 at 8:10 AM, Mike Frysinger wrote: > On 08 Feb 2016 10:38, Chet Ramey wro

Re: Bogus value of variable BASH

2016-02-09 Thread Piotr Grzybowski
hi, I think the logic behind variables.c:723 get_bash_name is in this case: put into BASH whatever valid command given to exec -a . E.g.: if you put exec -a /bin/ksh /bin/bash and /bin/ksh exists and is executable it will be seen in BASH variable. sincerely, pg On Tue, Feb 9, 2016 at 1:09 AM

Re: bug when 'cd ..' to a directory who's parent has been deleted

2016-02-09 Thread Andreas Schwab
Linda Walsh writes: > You can't open a file handle on a file. The fd comes from some > OS call associating it with the file on disk (or some other connection). You have to decide which sentence is true. Andreas. -