Subject: bug#24063: 25.1; Emacs 25.1 RC1 crashes on Solaris 11.3 when asked to open and display an image

From: Henry Unger <[email-masked]>
Date: Mon, 25 Jul 2016 00:00:06 -0700

> From: Eli Zaretskii [mailto:[email-masked]]
> Sent: Sunday, July 24, 2016 7:32 PM
> To: Henry Unger <[email-masked]>
> Cc: [email-masked]
> Subject: Re: bug#24063: 25.1; Emacs 25.1 RC1 crashes on Solaris 11.3 when
> asked to open and display an image
> 
> > From: Henry Unger <[email-masked]>
> > Date: Sun, 24 Jul 2016 14:29:49 -0700
> >
> > >From Dired, open any graphic file.
> >
> >
> > >From dbx:
> >
> > dbx) where
> > current thread: t@1
> > =>[1] __lwp_sigqueue(0x0, 0x1, 0xb, 0x0, 0xffffffff, 0x0, 0xb, 0x6105b88),
> at 0x610cf85
> >   [2] thr_kill(0x1, 0xb, 0x8511298, 0x60af2e1), at 0x6105bb2
> >   [3] raise(0xb, 0x85112b0, 0x0, 0x0, 0x400, 0x0), at 0x60af2ed
> >   [4] terminate_due_to_signal(0xb, 0x28, 0x0, 0x1, 0x614ecc0, 0x614a000),
> at 0x81d6be5
> >   [5] deliver_fatal_signal(0x0, 0x1, 0xb, 0x0, 0xffffffff, 0x0), at 0x81f6f65
> >   [6] deliver_thread_signal(0xb, 0x81f6f4c, 0xfeffe78f, 0x405a, 0x614ecc0,
> 0x0), at 0x81f6f3c
> >   [7] deliver_fatal_thread_signal(0xb, 0x1, 0x614e5c0, 0x1, 0x0, 0x0, 0x0,
> 0xdf41c, 0x60df41c), at 0x81f6f99
> >   [8] handle_sigsegv(0xb, 0x851199c, 0x851144c, 0x60df3f7, 0xb,
> 0x614a000), at 0x81f7100
> >   [9] __sighndlr(0xb, 0x851199c, 0x851144c, 0x81f708c), at 0x61084b5
> >   [10] call_user_handler(0xb), at 0x60fb10e
> >   [11] sigacthandler(0xb, 0x851199c, 0x851144c, 0x1f, 0x0, 0x0), at 0x60fb5a6
> >   ---- called from signal handler with signal 11 (SIGSEGV) ------
> >   [12] imagemagick_load_image(0x8a0a100, 0x8b06a40, 0x0, 0x0, 0x8cc2fec,
> 0xe70), at 0x82e3f06
> >   [13] imagemagick_load(0x8a0a100, 0x8b06a40, 0x1e14050, 0xe70,
> > 0x89eb955, 0x0), at 0x82e4130
> 
> Thanks.  Can you add source line numbers to the backtrace?

I rebuilt it, adding "-g" to CFLAGS, and  reproduced the problem, which now shows line numbers:

current thread: t@1
  [1] __lwp_sigqueue(0x0, 0x1, 0xb, 0x0, 0xffffffff, 0x0, 0xb, 0x6105b88), at 0x610cf85
  [2] thr_kill(0x1, 0xb, 0x8511298, 0x60af2e1), at 0x6105bb2
  [3] raise(0xb, 0x85112b0, 0x0, 0x0, 0x400, 0x0), at 0x60af2ed
=>[4] terminate_due_to_signal(sig = 11, backtrace_limit = 40), line 381 in "emacs.c"
  [5] deliver_fatal_signal(sig = <bad address 0x00000004>), line 1607 in "sysdep.c"
  [6] deliver_thread_signal(sig = 11, handler = 0x81f6f4c = &`emacs`sysdep.c`handle_fatal_signal(int sig)), line 1575 in "sysdep.c"
  [7] deliver_fatal_thread_signal(sig = 11), line 1613 in "sysdep.c"
  [8] handle_sigsegv(sig = 11, siginfo = 0x851199c, arg = 0x851144c), line 1695 in "sysdep.c"
  [9] __sighndlr(0xb, 0x851199c, 0x851144c, 0x81f708c), at 0x61084b5
  [10] call_user_handler(0xb), at 0x60fb10e
  [11] sigacthandler(0xb, 0x851199c, 0x851144c, 0x1f, 0x0, 0x0), at 0x60fb5a6
  ---- called from signal handler with signal 11 (SIGSEGV) ------
  [12] imagemagick_load_image(f = 0x8a0c5a8, img = 0x8afcd00, contents = (nil), size = 0, filename = 0x8caa450 "/home/hunger/foo.png"), line 8787 in "image.c"
  [13] imagemagick_load(f = 0x8a0c5a8, img = 0x8afcd00), line 8853 in "image.c"
  [14] lookup_image(f = 0x8a0c5a8, spec = 147473323), line 1746 in "image.c"
  [15] Fimage_size(spec = 147473323, pixels = 21936, frame = 0), line 871 in "image.c"
  [16] Ffuncall(nargs = 4, args = 0xfeffb840), line 2700 in "eval.c"
  [17] exec_byte_code(bytestr = 139881620, vector = 145318029, maxdepth = 38, args_template = 3078, nargs = 2, args = 0xfeffbb80), line 880 in "bytecode.c"
  [18] funcall_lambda(fun = 145318093, nargs = 2, arg_vector = (nil)), line 2855 in "eval.c"
  [19] Ffuncall(nargs = 3, args = 0xfeffbb74), line 2742 in "eval.c"
  [20] exec_byte_code(bytestr = 147183476, vector = 147179237, maxdepth = 30, args_template = 2, nargs = 0, args = 0xfeffbec8), line 880 in "bytecode.c"
  [21] funcall_lambda(fun = 147179309, nargs = 0, arg_vector = (nil)), line 2855 in "eval.c"
  [22] Ffuncall(nargs = 1, args = 0xfeffbec4), line 2742 in "eval.c"
  [23] exec_byte_code(bytestr = 146751148, vector = 147177733, maxdepth = 62, args_template = 2, nargs = 0, args = 0xfeffc1f8), line 880 in "bytecode.c"
  [24] funcall_lambda(fun = 140606525, nargs = 0, arg_vector = (nil)), line 2855 in "eval.c"
  [25] Ffuncall(nargs = 1, args = 0xfeffc1f4), line 2742 in "eval.c"
  [26] exec_byte_code(bytestr = 146816956, vector = 140605773, maxdepth = 54, args_template = 2, nargs = 0, args = 0xfeffc550), line 880 in "bytecode.c"
  [27] funcall_lambda(fun = 140606005, nargs = 0, arg_vector = (nil)), line 2855 in "eval.c"
  [28] Ffuncall(nargs = 1, args = 0xfeffc54c), line 2742 in "eval.c"
  [29] exec_byte_code(bytestr = 137699276, vector = 137699293, maxdepth = 22, args_template = 2054, nargs = 2, args = 0xfeffc8a0), line 880 in "bytecode.c"
  [30] funcall_lambda(fun = 137699253, nargs = 2, arg_vector = (nil)), line 2855 in "eval.c"
  [31] Ffuncall(nargs = 3, args = 0xfeffc894), line 2742 in "eval.c"
  [32] exec_byte_code(bytestr = 137698748, vector = 137698765, maxdepth = 50, args_template = 1026, nargs = 0, args = 0xfeffcbcc), line 880 in "bytecode.c"
  [33] funcall_lambda(fun = 137698725, nargs = 0, arg_vector = (nil)), line 2855 in "eval.c"
  [34] Ffuncall(nargs = 1, args = 0xfeffcbc8), line 2742 in "eval.c"
  [35] exec_byte_code(bytestr = 137693684, vector = 137693701, maxdepth = 22, args_template = 1026, nargs = 1, args = 0xfeffcf10), line 880 in "bytecode.c"
  [36] funcall_lambda(fun = 137693653, nargs = 1, arg_vector = (nil)), line 2855 in "eval.c"
  [37] Ffuncall(nargs = 2, args = 0xfeffcf08), line 2742 in "eval.c"
  [38] exec_byte_code(bytestr = 137693204, vector = 137693221, maxdepth = 42, args_template = 5122, nargs = 2, args = 0xfeffd25c), line 880 in "bytecode.c"
  [39] funcall_lambda(fun = 137693181, nargs = 2, arg_vector = (nil)), line 2855 in "eval.c"
  [40] Ffuncall(nargs = 3, args = 0xfeffd250), line 2742 in "eval.c"
  [41] exec_byte_code(bytestr = 137692284, vector = 137692301, maxdepth = 46, args_template = 6170, nargs = 6, args = 0xfeffd5b4), line 880 in "bytecode.c"
  [42] funcall_lambda(fun = 137692261, nargs = 6, arg_vector = (nil)), line 2855 in "eval.c"
  [43] Ffuncall(nargs = 7, args = 0xfeffd598), line 2742 in "eval.c"
  [44] exec_byte_code(bytestr = 137691604, vector = 137691621, maxdepth = 70, args_template = 4102, nargs = 4, args = 0xfeffd8f0), line 880 in "bytecode.c"
  [45] funcall_lambda(fun = 137691581, nargs = 4, arg_vector = (nil)), line 2855 in "eval.c"
  [46] Ffuncall(nargs = 5, args = 0xfeffd8dc), line 2742 in "eval.c"
  [47] exec_byte_code(bytestr = 137688164, vector = 137688181, maxdepth = 30, args_template = 2054, nargs = 1, args = 0xfeffdc0c), line 880 in "bytecode.c"
  [48] funcall_lambda(fun = 137688133, nargs = 1, arg_vector = (nil)), line 2855 in "eval.c"
  [49] Ffuncall(nargs = 2, args = 0xfeffdc04), line 2742 in "eval.c"
  [50] exec_byte_code(bytestr = 145733324, vector = 141664597, maxdepth = 10, args_template = 2, nargs = 0, args = 0xfeffe074), line 880 in "bytecode.c"
  [51] funcall_lambda(fun = 142656525, nargs = 0, arg_vector = (nil)), line 2855 in "eval.c"
  [52] Ffuncall(nargs = 1, args = 0xfeffe070), line 2742 in "eval.c"
  [53] Ffuncall_interactively(nargs = 1, args = 0xfeffe070), line 252 in "callint.c"
  [54] Ffuncall(nargs = 2, args = 0xfeffe06c), line 2673 in "eval.c"
  [55] Fapply(nargs = 3, args = 0xfeffe06c), line 2274 in "eval.c"
  [56] Fcall_interactively(function = 6460208, record_flag = 0, keys = 139692925), line 389 in "callint.c"
  [57] Ffuncall(nargs = 4, args = 0xfeffe1fc), line 2700 in "eval.c"
  [58] exec_byte_code(bytestr = 137934628, vector = 137934645, maxdepth = 54, args_template = 4102, nargs = 1, args = 0xfeffe540), line 880 in "bytecode.c"
  [59] funcall_lambda(fun = 137934605, nargs = 1, arg_vector = (nil)), line 2855 in "eval.c"
  [60] Ffuncall(nargs = 2, args = 0xfeffe538), line 2742 in "eval.c"
  [61] call1(fn = 7368, arg1 = 6460208), line 2552 in "eval.c"
  [62] command_loop_1(), line 1479 in "keyboard.c"
  [63] internal_condition_case(bfun = 0x81daae9 = &command_loop_1(), handlers = 9456, hfun = 0x81da31b = &`emacs`keyboard.c`cmd_error(Lisp_Object data)), line 1309 in "eval.c"
  [64] command_loop_2(ignore = 0), line 1107 in "keyboard.c"
  [65] internal_catch(tag = 22632, func = 0x81da7e0 = &`emacs`keyboard.c`command_loop_2(Lisp_Object ignore), arg = 0), line 1074 in "eval.c"
  [66] command_loop(), line 1086 in "keyboard.c"
  [67] recursive_edit_1(), line 692 in "keyboard.c"
  [68] Frecursive_edit(), line 763 in "keyboard.c"
  [69] main(argc = 1, argv = 0xfeffe814), line 1626 in "emacs.c"

> 
> Also, did you try any of the pretests, and if so, did they work correctly in
> these cases?

I did try the pretests and the same problem was present in all of them. I'm sorry I did not report the problem sooner.

Emacs 24.3.1 does not crash running on the same system.