From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: YAMAMOTO Mitsuharu Newsgroups: gmane.emacs.devel Subject: Re: usr1-signal, usr2-signal, etc. Date: Fri, 08 Dec 2006 19:28:33 +0900 Organization: Faculty of Science, Chiba University Message-ID: References: <85fybuuggr.fsf@lola.goethe.zz> NNTP-Posting-Host: dough.gmane.org Mime-Version: 1.0 (generated by SEMI 1.14.6 - "Maruoka") Content-Type: text/plain; charset=US-ASCII X-Trace: sea.gmane.org 1165573750 11037 80.91.229.10 (8 Dec 2006 10:29:10 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Fri, 8 Dec 2006 10:29:10 +0000 (UTC) Cc: rms@gnu.org, emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Fri Dec 08 11:29:07 2006 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by dough.gmane.org with esmtp (Exim 4.50) id 1GscyT-0000fX-Oq for ged-emacs-devel@m.gmane.org; Fri, 08 Dec 2006 11:29:02 +0100 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1GscyT-0003IK-5e for ged-emacs-devel@m.gmane.org; Fri, 08 Dec 2006 05:29:01 -0500 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1GscyC-0003GH-CX for emacs-devel@gnu.org; Fri, 08 Dec 2006 05:28:44 -0500 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1GscyA-0003Ce-AD for emacs-devel@gnu.org; Fri, 08 Dec 2006 05:28:43 -0500 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1GscyA-0003CS-57 for emacs-devel@gnu.org; Fri, 08 Dec 2006 05:28:42 -0500 Original-Received: from [133.82.132.2] (helo=mathmail.math.s.chiba-u.ac.jp) by monty-python.gnu.org with esmtp (Exim 4.52) id 1Gscy5-0007Vv-Q7; Fri, 08 Dec 2006 05:28:38 -0500 Original-Received: from church.math.s.chiba-u.ac.jp (church [133.82.132.36]) by mathmail.math.s.chiba-u.ac.jp (Postfix) with ESMTP id 715892CB1; Fri, 8 Dec 2006 19:28:33 +0900 (JST) Original-To: storm@cua.dk (Kim F. Storm) In-Reply-To: User-Agent: Wanderlust/2.14.0 (Africa) SEMI/1.14.6 (Maruoka) FLIM/1.14.8 (=?ISO-8859-4?Q?Shij=F2?=) APEL/10.6 Emacs/22.0.91 (sparc-sun-solaris2.8) MULE/5.0 (SAKAKI) X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:63461 Archived-At: >>>>> On Tue, 05 Dec 2006 23:51:03 +0100, storm@cua.dk (Kim F. Storm) said: > AFAICS, kbd_buffer_store_event[_hold] is usually called inside > BLOCK_INPUT, but there may be a few places where this is not the > case, notably in keyboard.c (and in the signal handler). > Would someone pls. check [and fix] this?? One way could be to abort > in kbd_buffer_store_event_hold if called without input blocked. All indirect calls from (*read_socket_hook), Fx_file_dialog, xmenu_show, or xdialog_show are inside BLOCK_INPUT. But some calls are not, because the current code (except handle_user_signal) assumes that at most one signal handler will call kbd_buffer_store_event_hold asynchronously, I think. * record_asynch_buffer_change either blocks SIGIO or stops polling before calling kbd_buffer_store_event_hold. * The remaining case is the calls from read_avail_input: - gobble_input -> read_avail_input: Like record_asynch_buffer_change above. - input_available_signal -> handle_async_input -> read_avail_input: Inside the SIGIO handler and not interrupted by the same signal. - Other handle_async_input -> read_avail_input: Inside #ifdef SYNC_INPUT. If polling used: - poll_for_input -> poll_for_input_1 -> read_avail_input: Inside the SIGALRM handler and not interrupted by the same signal. - x_make_frame_visible -> poll_for_input_1 -> read_avail_input: poll_suppress_count is set. - read_char -> kbd_buffer_get_event -> read_avail_input: After STOP_POLLING. YAMAMOTO Mitsuharu mituharu@math.s.chiba-u.ac.jp