Subject: bug#16739: 24.3.50; composition-get-gstring: wrong argument order causes crash

From: Dmitry Antipov <[email-masked]>
Date: Thu, 13 Feb 2014 14:08:14 +0400

1) emacs -Q

This is expected to be from 10 to 20, but...

2) (staying in *scratch*) M-x eval-expression (composition-get-gstring 20 10 nil nil) ==>

Program received signal SIGABRT, Aborted.
0x000000379220f62b in raise (sig=6) at ../nptl/sysdeps/unix/sysv/linux/pt-raise.c:37
37	  return INLINE_SYSCALL (tgkill, 3, pid, THREAD_GETMEM (THREAD_SELF, tid),
(gdb) bt
#0  0x000000379220f62b in raise (sig=6) at ../nptl/sysdeps/unix/sysv/linux/pt-raise.c:37
#1  0x000000000056533b in terminate_due_to_signal (sig=6, backtrace_limit=2147483647) at ../../trunk/src/emacs.c:378
#2  0x00000000005eb7e1 in die (msg=0x6f95fe "VECTORLIKEP (a)", file=0x6f95b8 "../../trunk/src/lisp.h", line=827)
     at ../../trunk/src/alloc.c:6761
#3  0x00000000005605ad in XVECTOR (a=...) at ../../trunk/src/lisp.h:827
#4  0x00000000005611ce in ASIZE (array=...) at ../../trunk/src/lisp.h:1326
#5  0x0000000000561208 in ASET (array=..., idx=0, val=...) at ../../trunk/src/lisp.h:1332
#6  0x0000000000684a6f in fill_gstring_body (gstring=...) at ../../trunk/src/composite.c:859
#7  0x0000000000688453 in Fcomposition_get_gstring (from=..., to=..., font_object=..., string=...)
     at ../../trunk/src/composite.c:1768

Dmitry