Subject: bug#16040: 24.3.50: r115361 broke Xlib/Lucid/Motif build

From: Dmitry Antipov <[email-masked]>
Date: Tue, 03 Dec 2013 19:17:04 +0400

Configure as follows:

./configure --disable-acl --without-all --with-x-toolkit=no \
	    --enable-gcc-warnings --enable-check-lisp-object-type \
	    --enable-checking

./src/emacs -Q ==>

../../trunk/src/xdisp.c:1048: Emacs fatal error: assertion failed: height >= 0
Fatal error 6: Aborted

Backtrace:

#0  0x000000386a60ee6b in raise (sig=6) at ../nptl/sysdeps/unix/sysv/linux/pt-raise.c:37
#1  0x00000000005424c6 in terminate_due_to_signal (sig=6, backtrace_limit=2147483647) at ../../trunk/src/emacs.c:377
#2  0x00000000005c9368 in die (msg=0x6991a2 "height >= 0", file=0x699130 "../../trunk/src/xdisp.c", line=1048)
     at ../../trunk/src/alloc.c:6726
#3  0x000000000042a44e in window_box_height (w=0x127c4e8) at ../../trunk/src/xdisp.c:1048
#4  0x000000000040cfa4 in required_matrix_height (w=0x127c4e8) at ../../trunk/src/dispnew.c:1663
#5  0x000000000040d135 in allocate_matrices_for_window_redisplay (w=0x127c4e8) at ../../trunk/src/dispnew.c:1728
#6  0x000000000040dce9 in adjust_frame_glyphs_for_window_redisplay (f=0x127a618) at ../../trunk/src/dispnew.c:2032
#7  0x000000000040d1f0 in adjust_frame_glyphs (f=0x127a618) at ../../trunk/src/dispnew.c:1749
#8  0x0000000000528f62 in x_set_menu_bar_lines (f=0x127a618, value=..., oldval=...) at ../../trunk/src/xfns.c:1038
#9  0x0000000000421989 in x_set_frame_parameters (f=0x127a618, alist=...) at ../../trunk/src/frame.c:2932
#10 0x00000000004256a0 in x_default_parameter (f=0x127a618, alist=..., prop=..., deflt=..., xprop=0x0, xclass=0x0,
     type=RES_TYPE_NUMBER) at ../../trunk/src/frame.c:4006
#11 0x000000000052ce89 in Fx_create_frame (parms=...) at ../../trunk/src/xfns.c:3099
#12 0x00000000005eabb5 in Ffuncall (nargs=2, args=0x7fffffffb378) at ../../trunk/src/eval.c:2805
#13 0x0000000000634229 in exec_byte_code (bytestr=..., vector=..., maxdepth=..., args_template=..., nargs=0, args=0x0)
     at ../../trunk/src/bytecode.c:919
#14 0x00000000005eb845 in funcall_lambda (fun=..., nargs=1, arg_vector=0x99c2bd <pure+514077>) at ../../trunk/src/eval.c:3039
#15 0x00000000005ead90 in Ffuncall (nargs=2, args=0x7fffffffbbd8) at ../../trunk/src/eval.c:2854
#16 0x0000000000634229 in exec_byte_code (bytestr=..., vector=..., maxdepth=..., args_template=..., nargs=0, args=0x0)
     at ../../trunk/src/bytecode.c:919
#17 0x00000000005eb845 in funcall_lambda (fun=..., nargs=1, arg_vector=0xa38e6d <pure+1156045>) at ../../trunk/src/eval.c:3039
#18 0x00000000005ead90 in Ffuncall (nargs=2, args=0x7fffffffc438) at ../../trunk/src/eval.c:2854
#19 0x0000000000634229 in exec_byte_code (bytestr=..., vector=..., maxdepth=..., args_template=..., nargs=0, args=0x0)
     at ../../trunk/src/bytecode.c:919
#20 0x00000000005eb845 in funcall_lambda (fun=..., nargs=0, arg_vector=0xa37b6d <pure+1151181>) at ../../trunk/src/eval.c:3039
#21 0x00000000005ead90 in Ffuncall (nargs=1, args=0x7fffffffcca8) at ../../trunk/src/eval.c:2854
#22 0x0000000000634229 in exec_byte_code (bytestr=..., vector=..., maxdepth=..., args_template=..., nargs=0, args=0x7fffffffd578)
     at ../../trunk/src/bytecode.c:919
#23 0x00000000005eb3f8 in funcall_lambda (fun=..., nargs=0, arg_vector=0x7fffffffd578) at ../../trunk/src/eval.c:2973
#24 0x00000000005ead90 in Ffuncall (nargs=1, args=0x7fffffffd570) at ../../trunk/src/eval.c:2854
#25 0x0000000000634229 in exec_byte_code (bytestr=..., vector=..., maxdepth=..., args_template=..., nargs=0, args=0x7fffffffdd40)
     at ../../trunk/src/bytecode.c:919
#26 0x00000000005eb3f8 in funcall_lambda (fun=..., nargs=0, arg_vector=0x7fffffffdd40) at ../../trunk/src/eval.c:2973
#27 0x00000000005eb0c2 in apply_lambda (fun=..., args=...) at ../../trunk/src/eval.c:2914
#28 0x00000000005e9655 in eval_sub (form=...) at ../../trunk/src/eval.c:2220
#29 0x00000000005e8b78 in Feval (form=..., lexical=...) at ../../trunk/src/eval.c:1993
#30 0x0000000000546768 in top_level_2 () at ../../trunk/src/keyboard.c:1179
#31 0x00000000005e711d in internal_condition_case (bfun=0x546751 <top_level_2>, handlers=..., hfun=0x54626c <cmd_error>)
     at ../../trunk/src/eval.c:1344
#32 0x000000000054679f in top_level_1 (ignore=...) at ../../trunk/src/keyboard.c:1187
#33 0x00000000005e65a0 in internal_catch (tag=..., func=0x54676a <top_level_1>, arg=...) at ../../trunk/src/eval.c:1108
#34 0x00000000005466cd in command_loop () at ../../trunk/src/keyboard.c:1148
#35 0x0000000000545d98 in recursive_edit_1 () at ../../trunk/src/keyboard.c:777
#36 0x0000000000545f68 in Frecursive_edit () at ../../trunk/src/keyboard.c:841
#37 0x0000000000543e09 in main (argc=2, argv=0x7fffffffe358) at ../../trunk/src/emacs.c:1598

The same issue exists with Lucid (--with-x-toolkit=lucid)
and Motif (--with-x-toolkit=motif) builds.

Previous revision r115360 is free from this issue.

Dmitry