From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.bugs Subject: bug#12426: 24.2.50; Emacs is closed unexpectedly after query-replace Date: Wed, 12 Sep 2012 22:02:11 +0300 Message-ID: <83627jvzd8.fsf@gnu.org> References: <837grzw0ek.fsf@gnu.org> Reply-To: Eli Zaretskii NNTP-Posting-Host: plane.gmane.org X-Trace: ger.gmane.org 1347476544 13809 80.91.229.3 (12 Sep 2012 19:02:24 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Wed, 12 Sep 2012 19:02:24 +0000 (UTC) Cc: 12426@debbugs.gnu.org To: Dmitry Antipov Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Wed Sep 12 21:02:27 2012 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1TBsCg-0006AU-CG for geb-bug-gnu-emacs@m.gmane.org; Wed, 12 Sep 2012 21:02:26 +0200 Original-Received: from localhost ([::1]:47806 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TBsCc-0002jF-Pn for geb-bug-gnu-emacs@m.gmane.org; Wed, 12 Sep 2012 15:02:22 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:37391) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TBsCa-0002iy-0j for bug-gnu-emacs@gnu.org; Wed, 12 Sep 2012 15:02:21 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1TBsCV-0007to-H4 for bug-gnu-emacs@gnu.org; Wed, 12 Sep 2012 15:02:19 -0400 Original-Received: from debbugs.gnu.org ([140.186.70.43]:48142) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TBsCV-0007tj-CY for bug-gnu-emacs@gnu.org; Wed, 12 Sep 2012 15:02:15 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.72) (envelope-from ) id 1TBsDF-00012b-HO for bug-gnu-emacs@gnu.org; Wed, 12 Sep 2012 15:03:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Wed, 12 Sep 2012 19:03:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 12426 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 12426-submit@debbugs.gnu.org id=B12426.13474765733987 (code B ref 12426); Wed, 12 Sep 2012 19:03:01 +0000 Original-Received: (at 12426) by debbugs.gnu.org; 12 Sep 2012 19:02:53 +0000 Original-Received: from localhost ([127.0.0.1]:57688 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TBsD6-00012G-06 for submit@debbugs.gnu.org; Wed, 12 Sep 2012 15:02:53 -0400 Original-Received: from mtaout20.012.net.il ([80.179.55.166]:44530) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TBsD3-000128-HK for 12426@debbugs.gnu.org; Wed, 12 Sep 2012 15:02:50 -0400 Original-Received: from conversion-daemon.a-mtaout20.012.net.il by a-mtaout20.012.net.il (HyperSendmail v2007.08) id <0MA9002003DMRJ00@a-mtaout20.012.net.il> for 12426@debbugs.gnu.org; Wed, 12 Sep 2012 22:02:00 +0300 (IDT) Original-Received: from HOME-C4E4A596F7 ([87.69.4.28]) by a-mtaout20.012.net.il (HyperSendmail v2007.08) with ESMTPA id <0MA9002N33JC9RA0@a-mtaout20.012.net.il>; Wed, 12 Sep 2012 22:02:00 +0300 (IDT) In-reply-to: <837grzw0ek.fsf@gnu.org> X-012-Sender: halo1@inter.net.il X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 2) X-Received-From: 140.186.70.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:64208 Archived-At: > Date: Wed, 12 Sep 2012 21:39:47 +0300 > From: Eli Zaretskii > Cc: 12426@debbugs.gnu.org > > > Date: Wed, 12 Sep 2012 20:06:03 +0200 > > From: Dani Moncayo > > > > Recipe from emacs -Q: a b M-a M-% a b c > > > > After doing that, my Emacs session suddenly ends. > > It exits due to an assertion violation. Looks like the recent changes > that introduced fatal_error_backtrace are a misfeature on Windows. > > I'm looking at the reason for the assertion violation; the > fatal_error_backtrace thingy is next. The reason for the assertion violation is the assertion in marker_position: eassert (BUF_BEG (buf) <= m->charpos && m->charpos <= BUF_Z (buf)); This was introduced recently by Dmitry, in revision 108906. A similar assertion was added to marker_byte_position. Dmitry, why did you add them? Who said that a marker cannot legitimately have a position outside of its buffer's range of character positions? For the record, here's the backtrace that leads to the assertion: (gdb) bt #0 0x01332b80 in exit () #1 0x01001447 in fatal_error_backtrace (sig=22, backtrace_limit=2147483647) at emacs.c:335 #2 0x01043379 in die ( msg=0x156236c "assertion failed: BUF_BEG (buf) <= m->charpos && m->charpos <= BUF_Z (buf)", file=0x1561e66 "marker.c", line=637) at alloc.c:6749 #3 0x0110ebd6 in marker_position (marker=55669099) at marker.c:637 #4 0x010ce3a9 in recenter_overlay_lists (buf=0x3447e00, pos=192) at buffer.c:3432 #5 0x010cebd3 in adjust_overlays_for_delete (pos=192, length=3) at buffer.c:3555 #6 0x011128ad in replace_range (from=192, to=195, new=56457521, prepare=true, inherit=false, markers=true) at insdel.c:1399 #7 0x01104833 in Freplace_match (newtext=56457521, fixedcase=54794266, literal=54794290, string=54794266, subexp=54794266) at search.c:2622 #8 0x0103652c in Ffuncall (nargs=4, args=0x82f0f4) at eval.c:2826 #9 0x0112664f in exec_byte_code (bytestr=21187937, vector=21188029, maxdepth=32, args_template=54794266, nargs=0, args=0x0) at bytecode.c:898 #10 0x01037261 in funcall_lambda (fun=21187877, nargs=5, arg_vector=0x82f368) at eval.c:3042 #11 0x0103674b in Ffuncall (nargs=6, args=0x82f364) at eval.c:2859 #12 0x0112664f in exec_byte_code (bytestr=21188625, vector=21189325, maxdepth=44, args_template=54794266, nargs=0, args=0x0) at bytecode.c:898 #13 0x01037261 in funcall_lambda (fun=21188533, nargs=9, arg_vector=0x82f5d8) at eval.c:3042 #14 0x0103674b in Ffuncall (nargs=10, args=0x82f5d4) at eval.c:2859 #15 0x0112664f in exec_byte_code (bytestr=21172369, vector=21172429, maxdepth=40, args_template=54794266, nargs=0, args=0x0) at bytecode.c:898 #16 0x01037261 in funcall_lambda (fun=21172309, nargs=5, arg_vector=0x82f844) at eval.c:3042 #17 0x0103674b in Ffuncall (nargs=6, args=0x82f840) at eval.c:2859 #18 0x01035550 in Fapply (nargs=2, args=0x82f8f0) at eval.c:2340 #19 0x01035ad4 in apply1 (fn=57177114, arg=58780478) at eval.c:2578 #20 0x011238ae in Fcall_interactively (function=57177114, record_flag=54794266, keys=54815661) at callint.c:378 #21 0x01036424 in Ffuncall (nargs=4, args=0x82fb30) at eval.c:2817 #22 0x01035ba9 in call3 (fn=54911794, arg1=57177114, arg2=54794266, arg3=54794266) at eval.c:2635 #23 0x010200e2 in Fcommand_execute (cmd=57177114, record_flag=54794266, keys=54794266, special=54794266) at keyboard.c:10378 #24 0x010065e5 in command_loop_1 () at keyboard.c:1626 #25 0x01032221 in internal_condition_case (bfun=0x100588b , handlers=54844922, hfun=0x100506e ) at eval.c:1319 #26 0x010054c8 in command_loop_2 (ignore=54794266) at keyboard.c:1193 #27 0x01031be3 in internal_catch (tag=54834754, func=0x10054a5 , arg=54794266) at eval.c:1076 #28 0x01005480 in command_loop () at keyboard.c:1172 #29 0x01004a2c in recursive_edit_1 () at keyboard.c:793 #30 0x01004d4e in Frecursive_edit () at keyboard.c:857 #31 0x010029d5 in main (argc=2, argv=0xa42808) at emacs.c:1660 Lisp Backtrace: "replace-match" (0x82f0f8) "replace-match-maybe-edit" (0x82f368) "perform-replace" (0x82f5d8) "query-replace" (0x82f844) "call-interactively" (0x82fb34)