[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Is fork() broken in octave 5.1 ?
From: |
Dr. K. nick |
Subject: |
Re: Is fork() broken in octave 5.1 ? |
Date: |
Fri, 27 Sep 2019 08:38:39 +0200 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.1.0 |
On 9/26/19 8:25 PM, John W. Eaton wrote:
> On 9/26/19 1:42 PM, Mike Miller wrote:
>> On Thu, Sep 26, 2019 at 19:27:55 +0200, Kay Nick wrote:
>>> Nevertheless I find this behavior not intuitive... What is the reason
>>> for preventing fork() from being used in a simple script?
>>
>> It is related to this (still open) bug report:
>> https://savannah.gnu.org/bugs/?45625
>
> Yes, the check was added to prevent simple calls to fork at the
> command line from creating two copies of Octave both competing for
> input from the terminal and possibly confusing users. Once this
> situation occurs, it can be difficult to recover from without killing
> the session.
>
> The check that was added doesn't distinguish between the command line
> and a script evaluated from the command line. A script executes in
> the scope of the caller and the check was for execution at the
> top-level scope rather than checking the depth of the call stack.
>
> Maybe we could change the condition so that it will allow fork if it
> is executed from a script but not directly from the command line.
>
> jwe
>
> Maybe we could change the condition so that it will allow fork if it
> is executed from a script but not directly from the command line.
This seems a reasonable thing to do as it would unbreak many scripts
that used to work with octave 3.8 and fail with 5.1.
> It is related to this (still open) bug report:
> https://savannah.gnu.org/bugs/?45625
Mike, thanks for that hint. I find it very helpful but seem to have
missed it when searching ...
Marcin
P. S. Is there some (new?) convention to add a reply beneath an
email/comment/statement it is referring to instead of above (as it used
to be?) ?
- Switch to std::atomic?, Rik, 2019/09/13
- Re: Switch to std::atomic?, John W. Eaton, 2019/09/25
- Re: Switch to std::atomic?, John W. Eaton, 2019/09/25
- Is fork() broken in octave 5.1 ?, Kay Nick, 2019/09/26
- Re: Is fork() broken in octave 5.1 ?, Mike Miller, 2019/09/26
- Re: Is fork() broken in octave 5.1 ?, Kay Nick, 2019/09/26
- Re: Is fork() broken in octave 5.1 ?, Mike Miller, 2019/09/26
- Re: Is fork() broken in octave 5.1 ?, John W. Eaton, 2019/09/26
- Re: Is fork() broken in octave 5.1 ?,
Dr. K. nick <=
- Re: Switch to std::atomic?, John W. Eaton, 2019/09/26
- Re: Switch to std::atomic?, Dmitri A. Sergatskov, 2019/09/26
- Re: Switch to std::atomic?, John W. Eaton, 2019/09/27
- Re: Switch to std::atomic?, Rik, 2019/09/26
- Re: Switch to std::atomic?, John W. Eaton, 2019/09/26
- Re: Switch to std::atomic?, Rik, 2019/09/26
- Re: Switch to std::atomic?, John W. Eaton, 2019/09/27
- Re: Switch to std::atomic?, Pantxo, 2019/09/27
- Re: Switch to std::atomic?, John W. Eaton, 2019/09/27
- Re: Switch to std::atomic?, Pantxo Diribarne, 2019/09/28