unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
From: Po Lu <luangruo@yahoo.com>
To: Eli Zaretskii <eliz@gnu.org>
Cc: emacs-devel@gnu.org
Subject: Re: Help with new Windows 98 crash
Date: Tue, 06 Dec 2022 09:29:04 +0800	[thread overview]
Message-ID: <87k035nwv3.fsf@yahoo.com> (raw)
In-Reply-To: <838rjl9477.fsf@gnu.org> (Eli Zaretskii's message of "Mon, 05 Dec 2022 18:59:40 +0200")

Eli Zaretskii <eliz@gnu.org> writes:

>> Date: Mon, 05 Dec 2022 16:52:28 +0200
>> From: Eli Zaretskii <eliz@gnu.org>
>> Cc: emacs-devel@gnu.org
>> 
>> > From: Po Lu <luangruo@yahoo.com>
>> > Date: Mon, 05 Dec 2022 22:18:18 +0800
>> > 
>> > Emacs 30 (with unexec) is crashing on Windows 98 again, this time during
>> > GC.
>> 
>> I tried to build it on X, but the build fails:
>> 
>>   xfns.c:46:10: fatal error: xcb/xcb_aux.h: No such file or directory
>>    #include <xcb/xcb_aux.h>
>> 	    ^~~~~~~~~~~~~~~
>>   compilation terminated.
>> 
>> can you please fix that?
>
> Never mind, I already fixed this.
>
>> Then I could see if the problem is not only Windows specific.
>
> Seems to be: the build on GNU/Linux doesn't crash.  Unless there's something
> special that I need to do to crash it.

I think I have figured it out.

init_bignum must be called before make_initial_frame, because that
allocates a bignum in temacs (as set_window_buffer calls
bset_display_time and Fcurrent_time, which go through the time
arithmetic stuff), before our own allocator has been set up, which ends
up in the dumped Emacs, leading to a free of a pointer from the wrong
heap once the bignum is garbage collected.

I have installed the change on the Emacs 30 branch because I am not sure
it is safe for Emacs 29.  Can you think of a safer fix?



  reply	other threads:[~2022-12-06  1:29 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <87o7sindcl.fsf.ref@yahoo.com>
2022-12-05 14:18 ` Help with new Windows 98 crash Po Lu
2022-12-05 14:52   ` Eli Zaretskii
2022-12-05 16:59     ` Eli Zaretskii
2022-12-06  1:29       ` Po Lu [this message]
2022-12-06 12:12         ` Eli Zaretskii
2022-12-06 12:53           ` Po Lu
2022-12-06 14:32             ` Eli Zaretskii
2022-12-07  0:59               ` Po Lu

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87k035nwv3.fsf@yahoo.com \
    --to=luangruo@yahoo.com \
    --cc=eliz@gnu.org \
    --cc=emacs-devel@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).