From mboxrd@z Thu Jan 1 00:00:00 1970 Path: main.gmane.org!not-for-mail From: storm@cua.dk (Kim F. Storm) Newsgroups: gmane.emacs.devel Subject: Re: xterm.c:handle_one_xevent question Date: 25 Feb 2004 11:33:17 +0100 Sender: emacs-devel-bounces+emacs-devel=quimby.gnus.org@gnu.org Message-ID: References: NNTP-Posting-Host: deer.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: sea.gmane.org 1077701795 1079 80.91.224.253 (25 Feb 2004 09:36:35 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Wed, 25 Feb 2004 09:36:35 +0000 (UTC) Cc: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+emacs-devel=quimby.gnus.org@gnu.org Wed Feb 25 10:36:18 2004 Return-path: Original-Received: from quimby.gnus.org ([80.91.224.244]) by deer.gmane.org with esmtp (Exim 3.35 #1 (Debian)) id 1AvvSj-0001Bl-00 for ; Wed, 25 Feb 2004 10:36:17 +0100 Original-Received: from monty-python.gnu.org ([199.232.76.173]) by quimby.gnus.org with esmtp (Exim 3.35 #1 (Debian)) id 1AvvSj-0006Y8-00 for ; Wed, 25 Feb 2004 10:36:17 +0100 Original-Received: from localhost ([127.0.0.1] helo=monty-python.gnu.org) by monty-python.gnu.org with esmtp (Exim 4.30) id 1AvvSJ-0000rY-Ud for emacs-devel@quimby.gnus.org; Wed, 25 Feb 2004 04:35:51 -0500 Original-Received: from list by monty-python.gnu.org with tmda-scanned (Exim 4.30) id 1AvvQt-0000Bn-6n for emacs-devel@gnu.org; Wed, 25 Feb 2004 04:34:23 -0500 Original-Received: from mail by monty-python.gnu.org with spam-scanned (Exim 4.30) id 1AvvQB-000828-4N for emacs-devel@gnu.org; Wed, 25 Feb 2004 04:34:12 -0500 Original-Received: from [212.88.64.25] (helo=mail-relay.sonofon.dk) by monty-python.gnu.org with smtp (Exim 4.30) id 1AvvQ3-0007xw-UN for emacs-devel@gnu.org; Wed, 25 Feb 2004 04:33:32 -0500 Original-Received: (qmail 80445 invoked from network); 25 Feb 2004 09:33:27 -0000 Original-Received: from unknown (HELO kfs-l.imdomain.dk.cua.dk) (213.83.150.2) by 0 with SMTP; 25 Feb 2004 09:33:27 -0000 Original-To: Miles Bader In-Reply-To: Original-Lines: 26 User-Agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.3.50 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:20174 X-Report-Spam: http://spam.gmane.org/gmane.emacs.devel:20174 Miles Bader writes: > I got an emacs abort at the following place in handle_one_xevent > (xterm.c): > It seems that my recent change to read_avail_input (which significantly reduced the size of the event buffer) has triggered some errors in the "read_socket_hook" functions on W32 and X (and probably MAC as well). The problem is that the numchars parameter indicating the buffer size is not checked to see how much can be stuffed into the buffer (and return when full), but rather [in an inconsistent way] to check that there is always sufficient space in the buffer or abort otherwise. I already posted a quick patch for W32 to this list, but haven't committed it yet, as the rest of the code should be cleaned up. If someone will commit it, you're welcome. I will go through the X and MAC code to see what's needed to fix this, but it will have to wait a few days, so if somebody else want to take up the challange, feel free to do so. -- Kim F. Storm http://www.cua.dk