Subject: bug#75632: 31.0.50; igc: Crash report

From: Eli Zaretskii <[email-masked]>
Date: Fri, 17 Jan 2025 23:04:57 +0200

> Date: Fri, 17 Jan 2025 20:52:58 +0000
> From: Pip Cet <[email-masked]>
> Cc: [email-masked], [email-masked]
> 
> "Eli Zaretskii" <[email-masked]> writes:
> 
> > This breaks the MS-Windows build: temacs crashes as below:
> 
> Sorry.  Can you try the fix I just pushed?  While I arrived at that
> independently (I was about to push when I got your email), I believe it
> explains your crash as well.

It fixes the crash, thanks.

> > The following patch seems to fix that, but I'm not sure it's the
> > correct fix.  Can you explain why we need to add-variable-watcher for
> > this in init_keyboard, in particular in temacs?
> 
> I'm not sure what you are suggesting here.  Is there a good place that
> is initialized only in the !pdumper || !temacs case?

The "if (initialized)" test is exactly for that.  pdumper_load sets
initialized = true before it returns.  So in temacs initialized will
be false when init_keyboard is called.

> I don't think so, but it might call Fadd_variable_watcher twice.  We
> should avoid that.

So maybe the patch I proposed should be installed regardless.