GNU bug report logs - #73838
31.0.50; Problems in note_mouse_highlight if -nw

Previous Next

Package: emacs;

Reported by: Gerd Möllmann <gerd.moellmann <at> gmail.com>

Date: Wed, 16 Oct 2024 10:48:02 UTC

Severity: normal

Found in version 31.0.50

Fixed in version 31.1

Done: Gerd Möllmann <gerd.moellmann <at> gmail.com>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Gerd Möllmann <gerd.moellmann <at> gmail.com>
To: 73838 <at> debbugs.gnu.org
Subject: bug#73838: 31.0.50; Problems in note_mouse_highlight if -nw
Date: Wed, 16 Oct 2024 16:19:53 +0200
[Message part 1 (text/plain, inline)]
Gerd Möllmann <gerd.moellmann <at> gmail.com> writes:

> This is with master fdac10b216f7b47e2eea129d2a96807a0c2055f3 on
> macOS, built with ASAN.
>
>   $ /Users/gerd/emacs/savannah/master/configure --cache-file /var/folders/1d/k_6t25f94sl83szqbf8gpkrh0000gn/T//config.cache.master --without-tree-sitter --with-native-compilation=no CC=clang 'LDFLAGS=-fsanitize=address -fno-omit-frame-pointer' 'CFLAGS=-Wgnu-imaginary-constant -Wunused-result -g -fno-omit-frame-pointer -g -O0 -fsanitize=address -fno-omit-frame-pointer'
>
> Recipe:
>
> - emacs -nw -q
> - M-x xterm-mouse-mode RET
> - M-x make TAB
> - Move the move over the completion candidates
>
> => ASAN abort in note_mouse_highlight, xdisp.c:36108
>
> The line number may vary. Looking at that in the debugger, I see
>
> 	default:
> 	  /* This should not happen.  */
> 	  if (cursor != FRAME_OUTPUT_DATA (f)->nontext_cursor)
> 	    cursor = FRAME_OUTPUT_DATA (f)->nontext_cursor;
>
> nsterm.h defines FRAME_OUTPUT_DATA(f) as
>
>   #define FRAME_OUTPUT_DATA(f) ((f)->output_data.ns)
>
> and since we are not in a GUI frame, this is no good. Analogous defines
> are in xterm.h etc., so the problem is not limited to macOS.
>
> (I built with ASAN because I observe weird things with mouse stuff in
> conjunction with tty child frames, and wanted to check what's up with
> that in master.)

I'd like to propose a change like in the attached patch (from my tty
child frames branch). It fixes the case I mentioned above.

[frame_output_data.patch (text/x-patch, attachment)]

This bug report was last modified 212 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.