Subject: Re: bug#19181: 24.4; 24.4.1 libgcc_s_dw2-1.dll crash on exit

From: Bill Farmer <[email-masked]>
Date: Wed, 26 Nov 2014 17:52:13 +0000

It does not seem to make any difference what file, I was using the 
grep-changelog file in the bin folder for testing, but any text or 
source file seems to cause the problem. I was visiting the file by 
dragging and dropping it into the emacs window. Visiting a file using 
the menu or 'C-x C-f' does not cause the problem. Starting emacs with 
emacs -Q crashes if a file is visited. I have attached a traceback from 
the zlib-available-p function. I couldn't paste it here because it 
contains null characters (^@).

Regards
Bill Farmer

On 26/11/2014 15:55, Eli Zaretskii wrote:
>> Date: Wed, 26 Nov 2014 11:34:52 +0000
>> From: Bill Farmer <[email-masked]>
>> CC: [email-masked], [email-masked]
>>
>> I have downloaded a built version of zlib1.dll from the zlib web site
>> (http://zlib.net) and copied the file into the bin folder of the emacs 24.4
>> distribution. This fixes the problem, as this version of zlib does not have a
>> dependency on libgcc_s_dw2-1.dll.
> Great, so your problem is solved.  I've now mentioned zlib1.dll in
> etc/PROBLEMS as the potential source of such crashes.
>
> However, I'd still like to understand why Emacs loads zlib1.dll when
> you visit a file.  Could you please help me figure that out?
>
> First, does that happen with any file, or just with a few particular
> ones, and if the latter, then which files trigger that?
>
> Second, how do you visit that file, exactly?  "C-x C-f", via the menu
> bar, something else?
>
> And finally, does Emacs load zlib1.dll if you invoke it as "emacs -Q"?
> If "emacs -Q" doesn't load zlib1.dll, can you try finding the
> customization in your ~/.emacs that causes this?
>
> There are only 2 functions in core Emacs that might load zlib:
> zlib-available-p and zlib-decompress-region.  So another way of
> finding out why zlib is being loaded is to "M-x debug-on-entry" both
> these functions, and when Emacs pops up the Lisp backtrace, see who
> called them.
>
> Thanks.