From mboxrd@z Thu Jan 1 00:00:00 1970 Path: main.gmane.org!not-for-mail From: Stefan Monnier Newsgroups: gmane.emacs.devel Subject: Recent change in intervals.c Date: 29 Sep 2003 15:04:31 -0400 Sender: emacs-devel-bounces+emacs-devel=quimby.gnus.org@gnu.org Message-ID: NNTP-Posting-Host: deer.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: sea.gmane.org 1064862450 16406 80.91.224.253 (29 Sep 2003 19:07:30 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Mon, 29 Sep 2003 19:07:30 +0000 (UTC) Original-X-From: emacs-devel-bounces+emacs-devel=quimby.gnus.org@gnu.org Mon Sep 29 21:07:26 2003 Return-path: Original-Received: from quimby.gnus.org ([80.91.224.244]) by deer.gmane.org with esmtp (Exim 3.35 #1 (Debian)) id 1A43Mk-0002ih-00 for ; Mon, 29 Sep 2003 21:07:26 +0200 Original-Received: from monty-python.gnu.org ([199.232.76.173]) by quimby.gnus.org with esmtp (Exim 3.35 #1 (Debian)) id 1A43Mj-0002tC-00 for ; Mon, 29 Sep 2003 21:07:25 +0200 Original-Received: from localhost ([127.0.0.1] helo=monty-python.gnu.org) by monty-python.gnu.org with esmtp (Exim 4.22) id 1A43Kr-00075M-D3 for emacs-devel@quimby.gnus.org; Mon, 29 Sep 2003 15:05:29 -0400 Original-Received: from list by monty-python.gnu.org with tmda-scanned (Exim 4.22) id 1A43Kc-000755-Vc for emacs-devel@gnu.org; Mon, 29 Sep 2003 15:05:14 -0400 Original-Received: from mail by monty-python.gnu.org with spam-scanned (Exim 4.22) id 1A43K5-0006zn-R1 for emacs-devel@gnu.org; Mon, 29 Sep 2003 15:05:13 -0400 Original-Received: from [132.204.24.67] (helo=mercure.iro.umontreal.ca) by monty-python.gnu.org with esmtp (Exim 4.22) id 1A43K4-0006yf-IQ for emacs-devel@gnu.org; Mon, 29 Sep 2003 15:04:40 -0400 Original-Received: from vor.iro.umontreal.ca (vor.iro.umontreal.ca [132.204.24.42]) by mercure.iro.umontreal.ca (8.12.9/8.12.9) with ESMTP id h8TJ4VKS020980 for ; Mon, 29 Sep 2003 15:04:32 -0400 Original-Received: by vor.iro.umontreal.ca (Postfix, from userid 20848) id 8671C3C547; Mon, 29 Sep 2003 15:04:31 -0400 (EDT) Original-To: emacs-devel@gnu.org Original-Lines: 27 User-Agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.3.50 X-MailScanner-DIRO: Found to be clean X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.2 Precedence: list List-Id: Emacs development discussions. List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+emacs-devel=quimby.gnus.org@gnu.org Xref: main.gmane.org gmane.emacs.devel:16775 X-Report-Spam: http://spam.gmane.org/gmane.emacs.devel:16775 Could someone double check that the patch below is correct and doesn't leave yet another "corner case" ? Stefan Index: intervals.c =================================================================== RCS file: /cvsroot/emacs/emacs/src/intervals.c,v retrieving revision 1.125 diff -u -u -b -r1.125 intervals.c --- intervals.c 22 Sep 2003 15:51:19 -0000 1.125 +++ intervals.c 29 Sep 2003 18:59:58 -0000 @@ -1823,9 +1968,9 @@ while (! NULL_INTERVAL_P (over)) { /* If UNDER is longer than OVER, split it. */ - if (LENGTH (over) < LENGTH (under)) + if (LENGTH (over) - over_used < LENGTH (under)) { - this = split_interval_left (under, LENGTH (over)); + this = split_interval_left (under, LENGTH (over) - over_used); copy_properties (under, this); } else