From ulrich@complang.tuwien.ac.at Wed May 28 04:33:12 2008 X-Spam-Checker-Version: SpamAssassin 3.2.3-bugs.debian.org_2005_01_02 (2007-08-08) on rzlab.ucr.edu X-Spam-Level: X-Spam-Status: No, score=-4.9 required=4.0 tests=BAYES_00,FOURLA, RCVD_IN_DNSWL_LOW autolearn=ham version=3.2.3-bugs.debian.org_2005_01_02 Received: (at submit) by emacsbugs.donarmstrong.com; 28 May 2008 11:33:12 +0000 Received: from lists.gnu.org (lists.gnu.org [199.232.76.165]) by rzlab.ucr.edu (8.13.8/8.13.8/Debian-3) with ESMTP id m4SBX7Af004504 for ; Wed, 28 May 2008 04:33:09 -0700 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1K1Jtz-0001pf-By for bug-gnu-emacs@gnu.org; Wed, 28 May 2008 07:33:07 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1K1Jty-0001pR-1x for bug-gnu-emacs@gnu.org; Wed, 28 May 2008 07:33:06 -0400 Received: from [199.232.76.173] (port=46918 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1K1Jtx-0001pO-Rz for bug-gnu-emacs@gnu.org; Wed, 28 May 2008 07:33:05 -0400 Received: from a4.complang.tuwien.ac.at ([128.130.173.65]:58700) by monty-python.gnu.org with esmtps (TLS-1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1K1Jtx-0007qR-LD for bug-gnu-emacs@gnu.org; Wed, 28 May 2008 07:33:05 -0400 Received: from ulrich by a4.complang.tuwien.ac.at with local (Exim 4.63) (envelope-from ) id 1K1Jtt-000190-Vk for bug-gnu-emacs@gnu.org; Wed, 28 May 2008 13:33:02 +0200 To: bug-gnu-emacs@gnu.org Subject: accept-process-output hangs (incompatibility) Message-Id: From: Ulrich Neumerkel Date: Wed, 28 May 2008 13:33:01 +0200 X-detected-kernel: by monty-python.gnu.org: Linux 2.6 (newer, 3) --text follows this line-- Please write in English if possible, because the Emacs maintainers usually do not have translators to read other languages for them. Your bug report will be posted to the bug-gnu-emacs@gnu.org mailing list, and to the gnu.emacs.bug news group. Please describe exactly what actions triggered the bug and the precise symptoms of the bug: Note: I reported that bug yesterday for an intermediary pre 22.2 version. The same problem occurs in 22.2 and is incompatible with previous versions: C-x C-e the following two expressions (progn (setq my-process (start-process "mine" "mine" "sleep" "1h")) (list-processes)) (accept-process-output my-process nil 400) We create a process mine, that sleeps for an hour. accept-process-output will hang, whereas it should return after 400 milliseconds. However, if argument SECONDS is replaced by 0 it will eval as expected. In GNU Emacs 22.2.1 (i686-pc-linux-gnu, X toolkit) of 2008-05-28 on gupu.complang.tuwien.ac.at Windowing system distributor `The XFree86 Project, Inc', version 11.0.4003 configured using `configure '--without-toolkit-scroll-bars' '--prefix' '/opt/gupu' '--with-git=no'' Important settings: value of $LC_ALL: nil value of $LC_COLLATE: nil value of $LC_CTYPE: nil value of $LC_MESSAGES: nil value of $LC_MONETARY: nil value of $LC_NUMERIC: nil value of $LC_TIME: nil value of $LANG: en_US locale-coding-system: iso-8859-1 default-enable-multibyte-characters: t Major mode: Emacs-Lisp Minor modes in effect: tooltip-mode: t tool-bar-mode: t mouse-wheel-mode: t menu-bar-mode: t file-name-shadow-mode: t global-font-lock-mode: t font-lock-mode: t blink-cursor-mode: t unify-8859-on-encoding-mode: t utf-translate-cjk-mode: t auto-compression-mode: t line-number-mode: t Recent input: M-x C-g C-x C-f ~ / l f t e m a / e C-x C-g C-k C-y C-a C-SPC C-w C-k C-k C-k C-k C-x C-s C-x C-e C-w C-x C-g C-/ C-x C-e C-g Recent messages: Loading help-mode...done Making completion list... [2 times] Mark set [2 times] Wrote /home/ulrich/lftp/emacs/e19.el nil Undo! Quit [2 times] Loading emacsbug... Loading regexp-opt...done Loading emacsbug...done From monnier@iro.umontreal.ca Thu May 29 07:07:39 2008 X-Spam-Checker-Version: SpamAssassin 3.2.3-bugs.debian.org_2005_01_02 (2007-08-08) on rzlab.ucr.edu X-Spam-Level: X-Spam-Status: No, score=-4.2 required=4.0 tests=AWL,BAYES_00,HAS_BUG_NUMBER, RCVD_IN_DNSWL_LOW autolearn=ham version=3.2.3-bugs.debian.org_2005_01_02 Received: (at submit) by emacsbugs.donarmstrong.com; 29 May 2008 14:07:40 +0000 Received: from lists.gnu.org (lists.gnu.org [199.232.76.165]) by rzlab.ucr.edu (8.13.8/8.13.8/Debian-3) with ESMTP id m4TE7Wkh008306 for ; Thu, 29 May 2008 07:07:34 -0700 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1K1imy-0000U3-M2 for bug-gnu-emacs@gnu.org; Thu, 29 May 2008 10:07:32 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1K1imx-0000TH-CP for bug-gnu-emacs@gnu.org; Thu, 29 May 2008 10:07:32 -0400 Received: from [199.232.76.173] (port=55759 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1K1imx-0000TE-6J for bug-gnu-emacs@gnu.org; Thu, 29 May 2008 10:07:31 -0400 Received: from 206-248-174-248.dsl.teksavvy.com ([206.248.174.248]:48277 helo=ceviche.home) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1K1imw-0002af-PQ for bug-gnu-emacs@gnu.org; Thu, 29 May 2008 10:07:30 -0400 Received: by ceviche.home (Postfix, from userid 20848) id A7A49B41E2; Thu, 29 May 2008 10:07:24 -0400 (EDT) From: Stefan Monnier To: Ulrich Neumerkel Cc: 332@debbugs.gnu.org, bug-gnu-emacs@gnu.org Subject: Re: bug#332: accept-process-output hangs (incompatibility) Message-ID: References: Date: Thu, 29 May 2008 10:07:24 -0400 In-Reply-To: (Ulrich Neumerkel's message of "Wed, 28 May 2008 13:33:01 +0200") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.0.60 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-detected-kernel: by monty-python.gnu.org: Linux 2.6 (newer, 3) X-CrossAssassin-Score: 2 > Note: I reported that bug yesterday for an intermediary pre 22.2 > version. The same problem occurs in 22.2 and is incompatible with > previous versions: Which previous versions accepted this form? The current behavior is in accordance with the docstring: Non-nil second arg seconds and third arg millisec are number of seconds and milliseconds to wait; return after that much time whether > We create a process mine, that sleeps for an hour. > accept-process-output will hang, whereas it should return after 400 > milliseconds. However, if argument SECONDS is replaced by 0 it will > eval as expected. BTW, I recommend you don't use the milliseconds argument at all. Stefan From ulrich@complang.tuwien.ac.at Thu May 29 07:18:37 2008 X-Spam-Checker-Version: SpamAssassin 3.2.3-bugs.debian.org_2005_01_02 (2007-08-08) on rzlab.ucr.edu X-Spam-Level: X-Spam-Status: No, score=-7.0 required=4.0 tests=AWL,BAYES_00,HAS_BUG_NUMBER, RCVD_IN_DNSWL_LOW autolearn=ham version=3.2.3-bugs.debian.org_2005_01_02 Received: (at submit) by emacsbugs.donarmstrong.com; 29 May 2008 14:18:38 +0000 Received: from lists.gnu.org (lists.gnu.org [199.232.76.165]) by rzlab.ucr.edu (8.13.8/8.13.8/Debian-3) with ESMTP id m4TEIU6n010697 for ; Thu, 29 May 2008 07:18:32 -0700 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1K1ixa-000492-Ic for bug-gnu-emacs@gnu.org; Thu, 29 May 2008 10:18:30 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1K1ixX-00046f-AC for bug-gnu-emacs@gnu.org; Thu, 29 May 2008 10:18:30 -0400 Received: from [199.232.76.173] (port=33603 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1K1ixX-00046c-5A for bug-gnu-emacs@gnu.org; Thu, 29 May 2008 10:18:27 -0400 Received: from a4.complang.tuwien.ac.at ([128.130.173.65]:52543) by monty-python.gnu.org with esmtps (TLS-1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1K1ixW-0004cu-Qq for bug-gnu-emacs@gnu.org; Thu, 29 May 2008 10:18:27 -0400 Received: from ulrich by a4.complang.tuwien.ac.at with local (Exim 4.63) (envelope-from ) id 1K1ixL-00058i-1W; Thu, 29 May 2008 16:18:15 +0200 To: monnier@iro.umontreal.ca, ulrich@complang.tuwien.ac.at Subject: Re: bug#332: accept-process-output hangs (incompatibility) Cc: 332@debbugs.gnu.org, bug-gnu-emacs@gnu.org In-Reply-To: Message-Id: From: Ulrich Neumerkel Date: Thu, 29 May 2008 16:18:15 +0200 X-detected-kernel: by monty-python.gnu.org: Linux 2.6 (newer, 3) X-CrossAssassin-Score: 2 > which previous versions accepted this form? GNU Emacs 21.3.50.1 (i686-pc-linux-gnu, X toolkit) of 2003-11-26 on gupu.complang.tuwien.ac.at GNU Emacs 21.2.50.2 (i686-pc-linux-gnu, X toolkit) of 2002-04-07 on gupu.complang.tuwien.ac.at GNU Emacs 20.7.1 (i386-redhat-linux-gnu, X toolkit) of Fri Mar 16 2001 on porky.devel.redhat.com ... and definitely many more. I never had any such problem ever since xemacs (not the Lucid successor, but the first tentative X versions of the real Emacs ~ 1992). All *.50.1 versions habe probably been pulled from cvs-archives at that time. Best regards, Ulrich From ulrich@complang.tuwien.ac.at Thu May 29 08:02:45 2008 X-Spam-Checker-Version: SpamAssassin 3.2.3-bugs.debian.org_2005_01_02 (2007-08-08) on rzlab.ucr.edu X-Spam-Level: X-Spam-Status: No, score=-7.4 required=4.0 tests=AWL,BAYES_00,HAS_BUG_NUMBER, RCVD_IN_DNSWL_LOW autolearn=ham version=3.2.3-bugs.debian.org_2005_01_02 Received: (at submit) by emacsbugs.donarmstrong.com; 29 May 2008 15:02:45 +0000 Received: from lists.gnu.org (lists.gnu.org [199.232.76.165]) by rzlab.ucr.edu (8.13.8/8.13.8/Debian-3) with ESMTP id m4TF2gQd021431 for ; Thu, 29 May 2008 08:02:43 -0700 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1K1jeL-0004Cp-S6 for bug-gnu-emacs@gnu.org; Thu, 29 May 2008 11:02:41 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1K1jeJ-0004C2-Pu for bug-gnu-emacs@gnu.org; Thu, 29 May 2008 11:02:41 -0400 Received: from [199.232.76.173] (port=35617 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1K1jeJ-0004Bx-Mh for bug-gnu-emacs@gnu.org; Thu, 29 May 2008 11:02:39 -0400 Received: from a4.complang.tuwien.ac.at ([128.130.173.65]:48907) by monty-python.gnu.org with esmtps (TLS-1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1K1jeJ-0007CT-1S for bug-gnu-emacs@gnu.org; Thu, 29 May 2008 11:02:39 -0400 Received: from ulrich by a4.complang.tuwien.ac.at with local (Exim 4.63) (envelope-from ) id 1K1jeG-0002EB-Pf; Thu, 29 May 2008 17:02:36 +0200 To: monnier@iro.umontreal.ca, ulrich@complang.tuwien.ac.at Subject: Re: bug#332: accept-process-output hangs (incompatibility) Cc: 332@debbugs.gnu.org, bug-gnu-emacs@gnu.org In-Reply-To: Message-Id: From: Ulrich Neumerkel Date: Thu, 29 May 2008 17:02:36 +0200 X-detected-kernel: by monty-python.gnu.org: Linux 2.6 (newer, 3) X-CrossAssassin-Score: 2 One further remark concerning the docstring: in 20.7 it read more or less the same: Non-nil second arg TIMEOUT and third arg TIMEOUT-MSECS are number of seconds and microseconds to wait; return after that much time whether or not there is input. From monnier@iro.umontreal.ca Thu May 29 09:58:02 2008 X-Spam-Checker-Version: SpamAssassin 3.2.3-bugs.debian.org_2005_01_02 (2007-08-08) on rzlab.ucr.edu X-Spam-Level: X-Spam-Status: No, score=-1.1 required=4.0 tests=AWL,BAYES_00,FOURLA, HAS_BUG_NUMBER,HELO_LH_HOME,MISSING_HEADERS,MURPHY_DRUGS_REL8,RDNS_DYNAMIC autolearn=no version=3.2.3-bugs.debian.org_2005_01_02 Received: (at 332-close) by emacsbugs.donarmstrong.com; 29 May 2008 16:58:02 +0000 Received: from ceviche.home (206-248-174-248.dsl.teksavvy.com [206.248.174.248]) by rzlab.ucr.edu (8.13.8/8.13.8/Debian-3) with ESMTP id m4TGvwGN017422 for <332-close@emacsbugs.donarmstrong.com>; Thu, 29 May 2008 09:58:00 -0700 Received: by ceviche.home (Postfix, from userid 20848) id D5186B41E2; Thu, 29 May 2008 12:57:57 -0400 (EDT) From: Stefan Monnier Cc: 332-close@debbugs.gnu.org Subject: Re: bug#332: accept-process-output hangs (incompatibility) Message-ID: References: Date: Thu, 29 May 2008 12:57:57 -0400 In-Reply-To: (Ulrich Neumerkel's message of "Thu, 29 May 2008 16:18:15 +0200") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.0.60 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii >> which previous versions accepted this form? > GNU Emacs 21.3.50.1 (i686-pc-linux-gnu, X toolkit) of 2003-11-26 on gupu.complang.tuwien.ac.at > GNU Emacs 21.2.50.2 (i686-pc-linux-gnu, X toolkit) of 2002-04-07 on gupu.complang.tuwien.ac.at > GNU Emacs 20.7.1 (i386-redhat-linux-gnu, X toolkit) of Fri Mar 16 2001 on porky.devel.redhat.com I've installed the patch below, which should fix your problem (note that the interpretation of the `millisec' argument has changed since Emacs-21 where it was a microseconds count). Stefan --- process.c.~1.542.~ 2008-05-22 17:12:27.000000000 -0400 +++ process.c 2008-05-29 12:52:17.000000000 -0400 @@ -3896,6 +3896,7 @@ seconds and milliseconds to wait; return after that much time whether or not there is input. If SECONDS is a floating point number, it specifies a fractional number of seconds to wait. +The MILLISEC argument is obsolete and should be avoided. If optional fourth arg JUST-THIS-ONE is non-nil, only accept output from PROCESS, suspending reading output from other processes. @@ -3911,6 +3912,18 @@ else just_this_one = Qnil; + if (!NILP (millisec)) + { /* Obsolete calling convention using integers rather than floats. */ + CHECK_NUMBER (millisec); + if (NILP (seconds)) + seconds = make_float (XINT (millisec) / 1000.0); + else + { + CHECK_NUMBER (seconds); + seconds = make_float (XINT (millisec) / 1000.0 + XINT (seconds)); + } + } + if (!NILP (seconds)) { if (INTEGERP (seconds)) @@ -3924,19 +3937,6 @@ else wrong_type_argument (Qnumberp, seconds); - if (INTEGERP (millisec)) - { - int carry; - usecs += XINT (millisec) * 1000; - carry = usecs / 1000000; - secs += carry; - if ((usecs -= carry * 1000000) < 0) - { - secs--; - usecs += 1000000; - } - } - if (secs < 0 || (secs == 0 && usecs == 0)) secs = -1, usecs = 0; } From unknown Fri Aug 15 15:34:26 2025 Received: (at fakecontrol) by fakecontrolmessage; To: internal_control@debbugs.gnu.org From: $requester Subject: Internal Control Message-Id: bug archived. Date: Fri, 27 Jun 2008 14:24:04 +0000 User-Agent: Fakemail v42.6.9 # A New Hope # A log time ago, in a galaxy far, far away # something happened. # # Magically this resulted in the following # action being taken, but this fake control # message doesn't tell you why it happened # # The action: # bug archived. thanks # This fakemail brought to you by your local debbugs # administrator