malloc crash

Ken Brown kbrown@cornell.edu
Mon Oct 25 13:37:35 GMT 2021


On 10/25/2021 4:56 AM, Takashi Yano wrote:
> On Sun, 24 Oct 2021 17:46:40 -0400
> Ken Brown wrote:
>> I'm trying to debug the fifo problem reported here:
>>
>>     https://cygwin.com/pipermail/cygwin/2021-October/249635.html
>>
>> To keep my email self-contained, here are the reproduction instructions.  Run
>> the attached script with argument 1000.  The output is supposed to look like this:
>>
>> $ ./fifo_test.sh 1000
>> Creating 1000 fifo readers...
>> Created PID=6503  reading from /tmp/catfifo_0
>> FIFO 0
>> Created PID=6506  reading from /tmp/catfifo_1
>> FIFO 1
>> [...]
>> Created PID=9506  reading from /tmp/catfifo_998
>> FIFO 998
>> Created PID=9509  reading from /tmp/catfifo_999
>> FIFO 999
>>
>> But invariably one of the exec'd cat processes will appear to hang.  (Actually
>> it goes into an infinite loop.)  If you attach gdb to that process and catch it
>> at the right time, you see something like this:
> 
> I noticed that this does not occur with 32-bit cygwin.
> This occurs only with 64-bit cygwin in my environment.

It hadn't occurred to me to test 32-bit, but I just tried, and I can't reproduce 
the problem in that environment either.

> Does malloc behave differently between 32 and 64 bit cygwin?

Ken


More information about the Cygwin-developers mailing list