From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: =?ISO-8859-1?Q?Jan_Dj=E4rv?= Newsgroups: gmane.emacs.devel Subject: Re: Reading D-Bus messages Date: Fri, 24 Sep 2010 16:28:14 +0200 Message-ID: <4C9CB57E.1010708@swipnet.se> References: <878w2tx6gk.fsf@gmx.de> <4C9A493F.4050701@cornell.edu> <874odhyliu.fsf@gmx.de> <4C9B452E.1040101@cornell.edu> <4C9B63A1.2060604@cornell.edu> <87y6asy0uh.fsf@gmx.de> <4C9BBD5C.30201@cornell.edu> <83tylgtbo8.fsf@gnu.org> <871v8jhcw2.fsf@gmx.de> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Trace: dough.gmane.org 1285338520 3038 80.91.229.12 (24 Sep 2010 14:28:40 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Fri, 24 Sep 2010 14:28:40 +0000 (UTC) Cc: Eli Zaretskii , Ken Brown , emacs-devel@gnu.org To: Michael Albinus Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Fri Sep 24 16:28:37 2010 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1Oz9GN-0000Jl-U6 for ged-emacs-devel@m.gmane.org; Fri, 24 Sep 2010 16:28:36 +0200 Original-Received: from localhost ([127.0.0.1]:39302 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Oz9GK-0004L7-1H for ged-emacs-devel@m.gmane.org; Fri, 24 Sep 2010 10:28:32 -0400 Original-Received: from [140.186.70.92] (port=35728 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Oz9GC-0004Je-Fl for emacs-devel@gnu.org; Fri, 24 Sep 2010 10:28:25 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.69) (envelope-from ) id 1Oz9G9-0007hq-Vn for emacs-devel@gnu.org; Fri, 24 Sep 2010 10:28:24 -0400 Original-Received: from smtprelay-b12.telenor.se ([62.127.194.21]:37262) by eggs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1Oz9G8-0007hE-H4; Fri, 24 Sep 2010 10:28:20 -0400 Original-Received: from ipb2.telenor.se (ipb2.telenor.se [195.54.127.165]) by smtprelay-b12.telenor.se (Postfix) with ESMTP id 24BD0E9F62; Fri, 24 Sep 2010 16:28:19 +0200 (CEST) X-SENDER-IP: [85.225.45.35] X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: Al1BAMZSnExV4S0jPGdsb2JhbACHbppSDAEBAQE1LcUMhUMEjTg X-IronPort-AV: E=Sophos;i="4.57,230,1283724000"; d="scan'208";a="133194541" Original-Received: from c-232de155.25-1-64736c10.cust.bredbandsbolaget.se (HELO coolsville.localdomain) ([85.225.45.35]) by ipb2.telenor.se with ESMTP; 24 Sep 2010 16:28:18 +0200 Original-Received: from [172.20.199.2] (gaffa [172.20.199.2]) by coolsville.localdomain (Postfix) with ESMTP id 377787FA05A; Fri, 24 Sep 2010 16:28:18 +0200 (CEST) User-Agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.1.12) Gecko/20100915 Thunderbird/3.0.8 In-Reply-To: <871v8jhcw2.fsf@gmx.de> X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. 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:130779 Archived-At: 2010-09-24 08:30, Michael Albinus skrev: > Eli Zaretskii writes: > >> I'd rather turn the table and ask why is the call to >> xd_read_queued_messages made in gobble_input and not elsewhere? Why >> are we mixing input from D-Bus with keyboard input? And why in >> gobble_input? > > D-Bus messages arrive asynchronously. xd_read_queued_messages() converts > them into special events, which are stored via kbd_buffer_store_event(). > > gobble_input() is used, because it is called at several places, for > instance in sit_for(), kbd_buffer_get_event(), get_input_pending(), > ns_select() - D-Bus messages shall be handled as soon as they arrive. > This is overkill. Not even X messages are processed this fast. Checking for D-bus messages when the input loop is entered should be enough. Jan D.